Rpm module manages rpm packages. Allows retrieval of currently installed rpms, querying repositories, and installation/upgrade of rpms using repositories. (rpm and up2date/yum frontend)
Module name: “rpm”
Module version: 1.0
See Modules - Common API for general module description.
Rpm module has a notion of rpm and set (set of rpms). Sets are here to simplify installation of multiple packages, eg cluster deployment.
<rpm name=”rpm name” summary=”summary”
description=”description” version=”installed version”
repo_version=”version in repository”/>
If “version” is
empty, rpm is not installed. If “repo_version” is empty, package
is not in repository. If “repo_version” > “version”,
package can be installed/upgraded.
<set name=”set name” summary=”summary”
description=”description” installed="true"
in_repository="true" installable="true"/>
If
installable is “true”, set of rpms can be installed, if not
installed; and upgraded, if already installed.
There are couple of predefined rpm sets:
- “Cluster Base”
- base infrastructure of Red Hat Cluster Suite (currently ccs, cman,
dlm, fence, and respective kernel-... rpms)
- “Cluster Base -
Gulm” - base infrastructure of Red Hat Cluster Suite using GULM lock
manager (currently ccs, gulm, and respective kernel-... rpms)
- “Cluster Service Manager” - (currently rgmanager, magma,
magma-plugins)
- “Clustered Storage” - shared storage
(currently GFS, lvm2-cluster and respective kernel-... rpms)
-
“Linux Virtual Server” - (currently ipvsadm, piranha)
Functions:
APIs
Get supported API versions. See Modules - Common API for description.
list
Retrieve list of installed rpms and rpms in
repository. Arguments specify the list of what is to be retrieved.
If neither “rpms” nor “sets” are specified, returned
list will be empty. List can be further tuned with “installed”,
“installable” and “upgradeable”.
Input variables:
- “rpms” (boolean) – optional,
retrieve list of rpms
- “sets” (boolean) – optional,
retrieve list of sets
- “installed” (boolean) – optional,
retrieve installed
- “installable” (boolean) – optional,
retrieve installable (in repo)
- “upgradeable” (boolean) –
optional, retrieve upgradeable (installed and in repo)
Output variables:
- “rpms” (list_xml) – list
of matching rpms
- “sets” (list_xml) - list of matching sets
On failure:
- No special errors defined, only
generic ones might get returned.
query
Query rpms and sets, both locally installed and in repository, by rpm/set name.
Input variables:
- “search” (list_xml) – list of rpms
and sets to query. Rpm format <rpm name=”rpm name”/>; set
format <set name=”set name”/>.
Output variables:
- “result” (list_xml) –
list of matching rpms and sets.
On failure:
- No special errors defined, only generic ones
might get returned.
install
Install/upgrade rpms and sets from repository.
Input variables:
- “rpms” (list_xml) – optional, list of rpms to
install/upgrade. Rpm format <rpm name=”rpm name”/>.
-
“sets” (list_xml) – optional, list of sets to install/upgrade. Set
format <set name=”set name”/>.
-
“upgrade” (boolean) – optional (defaults to true), upgrade already installed packages/sets.
No output variables.
On failure:
- No special errors defined, only generic ones
might get returned.
repository_configured
Is this managed system configured to use repository, and capable of retrieving rpms?
No input variables.
Output variables:
- “ repository_configured” (boolean) –
whether repository is available to this managed system
On failure:
- No special errors defined, only generic ones
might get returned.