rpmconf [ options ... ] [ -a, --all ] [ -o<package>, --owner=<package> ] [ -f<type> --frontend=<type> ] [ --root <ROOT> ] [ -c, --clean ] [ -d, --debug ] [ -D, --diff ] [ -t, --test ] [ -u, --unattended [<MODE>] ] [ -x, --exclude <DIRECTORY> ] [ -Z ]
Rpmconf will search for all config file of given package (or all installed packages) and will check if coresponding .rpmsave, .rpmnew or .rpmorig files exist. If so, you will be asked if you want to keep the current version, revert to the previous version, or diff the two files. The unwanted file is then deleted.
Additionally, rpmconf can also handle application configuration, if the application supports rpmconf. The application must have an executable file present in /usr/share/rpmconf/. The file must have the same name as package itself and the package must own that file. The executable must be idempotent, i.e. subsequent executions should have no effect. Ideally it should be a Puppet/Chef/Ansible/CFengine manifest.
- -a, --all
Check configuration files of all packages.
- -o<package>, --owner=<package>
Check only configuration files of given package.
- -f<type>, --frontend=<type>
Define which frontend should be used for merging. Valid options are: vimdiff, gvimdiff, diffuse, kdiff3, meld, sdiff and env. When set to env, the command to use is taken from the environment variable $MERGE. The default is env.
- -c, --clean
Find all .rpmnew and .rpmsave files in /etc and /var directories. List all files belonging to installed packages, then write all files which are orphaned and ask if it is safe to delete them.
- -d, --debug
Dry run. Instead of executing an action (move or delete a file) the filename will be echoed to standard output. However, the executable for merging of configuration files will still be executed. Beware that this option is position-sensitive: only actions specified after --debug are dry-run, e.g. --all --debug --clean will run --clean in dry run mode but not --all.
- -D, --diff
Non-interactive diff mode. This option works with --owner and --all. Useful to audit config files after package upgrades.
- --root ROOT
Specifies an alternative installroot, relative to where all packages are installed.
- -t, --test
Just test existence of files to merge. If there is some file to merge then rpmconf will print it and exit with status code 5. If there are none to merge, then exit with status code 0.
- -u [<MODE>], --unattended [<MODE>]
Unattended mode. Do not prompt user, but perform actions based on MODE. Valid options are: use_maintainer, use_your, default. use_maintainer replaces existing configuration files with .rpmnew files and deletes leftover .rpmsave and .rpmorig files. use_your deletes .rpmnew files and replaces existing configuration files with .rpmsave files. default does use_your for .rpmnew files and use_maintainer for .rpmsave files, as are the default prompts in interactive mode. Specifying MODE is optional, default is used by default.
- -V, --version
Display rpmconf version. This option expects that this script is installed as rpm package.
- -x, --exclude [DIRECTORY [DIRECTORY ...]]
Exclude DIRECTORY from checking. Applies only for -c.
Display the SELinux contexts of the old and new files. Note: if you choose to install .rpmsave version. It is copied to the original filename, therefore its SELinux context is reset to the default value specified by SELinux policy.
Miroslav Suchý <firstname.lastname@example.org>