crm_diff8
Part of the pacemaker cluster resource manager
Usage
crm_diff original_xml
operation
[options]
Overview
Compare two Pacemaker configurations (in XML format) to produce a custom diff-like output, or apply such an output as a patch
Options
Help Options:
-
-h, --help -
Show help options
-
--help-all -
Show all help options
-
--help-xml -
Show original XML options
-
--help-operation -
Show operation options
-
--help-additional -
Show additional options
Original XML:
-
-o, --original=FILE -
XML is contained in the named file
-
-O, --original-string=STRING -
XML is contained in the supplied string
Operation:
-
-n, --new=FILE -
Compare the original XML to the contents of the named file
-
-N, --new-string=STRING -
Compare the original XML with the contents of the supplied string
-
-p, --patch=FILE -
Patch the original XML with the contents of the named file
Additional Options:
-
-c, --cib -
Compare/patch the inputs as a CIB (includes versions details)
-s, --stdin
-
-u, --no-version -
Generate the difference without versions details
Application Options:
-
-$, --version -
Display software version and exit
-
-V, --verbose -
Increase debug output (may be specified multiple times)
Examples
Obtain the two different configuration files by running cibadmin on the two cluster setups to compare:
|
# cibadmin --query > cib-old.xml |
|
|
# cibadmin --query > cib-new.xml |
Calculate and save the difference between the two files:
-
# crm_diff --original cib-old.xml --new cib-new.xml > patch.xml
Apply the patch to the original file:
-
# crm_diff --original cib-old.xml --patch patch.xml > updated.xml
Apply the patch to the running cluster:
-
# cibadmin --patch -x patch.xml
Releases
6 releases since Debian 7 (Wheezy); the text changed 5 times.
--help-additional since Debian 11 (Bullseye);
--help-all since Debian 11 (Bullseye);
--help-operation since Debian 11 (Bullseye);
--help-xml since Debian 11 (Bullseye);
--no-version since Debian 9 (Stretch);
-h since Debian 11 (Bullseye);
-u since Debian 9 (Stretch).
--filter until Debian 7 (Wheezy);
-? until Debian 10 (Buster);
-f until Debian 7 (Wheezy).