Scroll to navigation

PACEMAKER(8) System Administration Utilities PACEMAKER(8)

NAME

Pacemaker - Part of the Pacemaker cluster resource manager

SYNOPSIS

cibadmin <command> [options]

DESCRIPTION

cibadmin - query and edit the Pacemaker configuration

OPTIONS

-?, --help
This text
-$, --version
Version information
Increase debug output

Commands:

Upgrade the configuration to the latest syntax
Query the contents of the CIB
Erase the contents of the whole CIB
Increase the CIB's epoch value by 1
Create an object in the CIB (will fail if object already exists)
Find object somewhere in CIB's XML tree and update it (fails if object does not exist unless -c is also specified)
Supply an update in the form of an XML diff (see crm_diff(8))
Recursively replace an object in the CIB
Delete first object matching supplied criteria (for example, <op id="rsc1_op1" name="monitor"/>)
The XML element name and all attributes must match in order for the element to be deleted.
When used with --xpath, remove all matching objects in the configuration instead of just the first one
Output an empty CIB
-5, --md5-sum
Calculate the on-disk CIB digest
-6, --md5-sum-versioned
Calculate an on-the-wire versioned CIB digest
Whether to use syntax highlighting for ACLs (with -Q/--query and -U/--user)
That amounts to one of "color" (default for terminal), "text" (otherwise), "namespace", or "auto" (per former defaults).

Additional options:

-f, --force

Time (in seconds) to wait before declaring the operation failed
Run the command with permissions of the named user (valid only for the root and hacluster accounts)
Wait for call to complete before returning
Command takes effect locally (should be used only for queries)
(Advanced) Allow target of --modify/-M to be created if it does not exist
(Advanced) When querying an object, do not include its children in the result

Data:

Retrieve XML from the supplied string
Retrieve XML from the named file

-p, --xml-pipe Retrieve XML from stdin

Limit scope of operation to specific section of CIB
Valid values: configuration, nodes, resources, constraints, crm_config, rsc_defaults, op_defaults, acls, fencing-topology, tags, alerts
A valid XPath to use instead of --scope/-o
When performing XPath queries, return path of any matches found
(for example, "/cib/configuration/resources/clone[@id='ms_RH1_SCS']/primitive[@id='prm_RH1_SCS']")
(Advanced) Send command to the specified host

EXAMPLES

Query the configuration from the local node:

# cibadmin --query --local

Query just the cluster options configuration:

# cibadmin --query --scope crm_config

Query all 'target-role' settings:

# cibadmin --query --xpath "//nvpair[@name='target-role']"

Remove all 'is-managed' settings:

# cibadmin --delete-all --xpath "//nvpair[@name='is-managed']"

Remove the resource named 'old':

# cibadmin --delete --xml-text '<primitive id="old"/>'

Remove all resources from the configuration:

# cibadmin --replace --scope resources --xml-text '<resources/>'

Replace complete configuration with contents of $HOME/pacemaker.xml:

# cibadmin --replace --xml-file $HOME/pacemaker.xml

Replace constraints section of configuration with contents of $HOME/constraints.xml:

# cibadmin --replace --scope constraints --xml-file $HOME/constraints.xml

Increase configuration version to prevent old configurations from being loaded accidentally:

# cibadmin --modify --xml-text '<cib admin_epoch="admin_epoch++"/>'

Edit the configuration with your favorite $EDITOR:

# cibadmin --query > $HOME/local.xml
# $EDITOR $HOME/local.xml
# cibadmin --replace --xml-file $HOME/local.xml

Assuming terminal, render configuration in color (green for writable, blue for readable, red for denied) to visualize permissions for user tony:

# cibadmin --show-access=color --query --user tony | less -r

SEE ALSO:

crm(8), pcs(8), crm_shadow(8), crm_diff(8)

AUTHOR

Written by Andrew Beekhof and the Pacemaker project contributors

REPORTING BUGS

Report bugs to users@clusterlabs.org

July 2022 Pacemaker 2.1.4