-
Notifications
You must be signed in to change notification settings - Fork 19
/
Copy pathrpmconf.sgml
196 lines (188 loc) · 7.23 KB
/
rpmconf.sgml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V3.1//EN" [
<!ENTITY SCRIPTNAME "rpmconf" >
<!ENTITY SCRIPTCOMMAND "rpmconf" >
]>
<refentry>
<RefMeta>
<RefEntryTitle>&SCRIPTCOMMAND;</RefEntryTitle><manvolnum>8</manvolnum>
<RefMiscInfo>Version 0.2</RefMiscInfo>
</RefMeta>
<RefNameDiv>
<RefName><command>&SCRIPTCOMMAND;</command></RefName>
<RefPurpose>
This tool searches for .rpmnew, .rpmsave and .rpmorig files and asks you what to do with them: keep the current version, replace with the previous version, or review the diff.
</RefPurpose>
</RefNameDiv>
<RefSynopsisDiv>
<Synopsis>
<cmdsynopsis>
<command>&SCRIPTCOMMAND;</command>
<arg>options <replaceable>...</replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>-a, --all</arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>-o<replaceable><package></replaceable>, --owner=<replaceable><package></replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>-f<replaceable><type></replaceable> --frontend=<replaceable><type></replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>--root <replaceable><ROOT></replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>-c, --clean</arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>-d, --debug</arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>-D, --diff</arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>-t, --test</arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>-u, --unattended <replaceable><optional><MODE></optional></replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>-x, --exclude <replaceable><DIRECTORY></replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<arg>-Z</arg>
</cmdsynopsis>
</Synopsis>
</RefSynopsisDiv>
<RefSect1><Title>Description</Title>
<para>
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.
</para>
<para>
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.
</para>
</RefSect1>
<RefSect1><Title>Options</Title>
<variablelist>
<varlistentry>
<term>-a, --all</term>
<listitem>
<para>Check configuration files of all packages.</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-o<package>, --owner=<package></term>
<listitem>
<para>Check only configuration files of given package.</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-f<type>, --frontend=<type></term>
<listitem>
<para>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.</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-c, --clean</term>
<listitem>
<para>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.</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-d, --debug</term>
<listitem>
<para>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.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-D, --diff</term>
<listitem>
<para>
Non-interactive diff mode.
This option works with <literal>--owner</literal> and <literal>--all</literal>.
Useful to audit config files after package upgrades.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>--root ROOT</term>
<listitem>
<para>
Specifies an alternative installroot, relative to where all packages are installed.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-t, --test</term>
<listitem>
<para>
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.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-u [<MODE>], --unattended [<MODE>]</term>
<listitem>
<para>
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.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-V, --version</term>
<listitem>
<para>
Display &SCRIPTCOMMAND; version. This option expects that this script
is installed as rpm package.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-x, --exclude [DIRECTORY [DIRECTORY ...]]</term>
<listitem>
<para>
Exclude DIRECTORY from checking. Applies only for -c.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-Z</term>
<listitem>
<para>
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.
</para>
</listitem>
</varlistentry>
</variablelist>
</RefSect1>
<RefSect1><Title>See Also</Title>
<simplelist>
<member>rpm(8)</member>
</simplelist>
</RefSect1>
<RefSect1><Title>Authors</Title>
<simplelist>
<member>Miroslav Suchý <email>[email protected]</email></member>
</simplelist>
</RefSect1>
</RefEntry>