Debian Codegraph @

upstream/fedora-44/man1/rpmorphan.1

raw
1 .\" -*- mode: troff; coding: utf-8 -*-
2 .\" Automatically generated by Pod::Man v6.0.2 (Pod::Simple 3.47)
3 .\"
4 .\" Standard preamble:
5 .\" ========================================================================
6 .de Sp \" Vertical space (when we can't use .PP)
7 .if t .sp .5v
8 .if n .sp
9 ..
10 .de Vb \" Begin verbatim text
11 .ft CW
12 .nf
13 .ne \\$1
14 ..
15 .de Ve \" End verbatim text
16 .ft R
17 .fi
18 ..
19 .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>.
20 .ie n \{\
21 . ds C` ""
22 . ds C' ""
23 'br\}
24 .el\{\
25 . ds C`
26 . ds C'
27 'br\}
28 .\"
29 .\" Escape single quotes in literal strings from groff's Unicode transform.
30 .ie \n(.g .ds Aq \(aq
31 .el .ds Aq '
32 .\"
33 .\" If the F register is >0, we'll generate index entries on stderr for
34 .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
35 .\" entries marked with X<> in POD. Of course, you'll have to process the
36 .\" output yourself in some meaningful fashion.
37 .\"
38 .\" Avoid warning from groff about undefined register 'F'.
39 .de IX
40 ..
41 .nr rF 0
42 .if \n(.g .if rF .nr rF 1
43 .if (\n(rF:(\n(.g==0)) \{\
44 . if \nF \{\
45 . de IX
46 . tm Index:\\$1\t\\n%\t"\\$2"
47 ..
48 . if !\nF==2 \{\
49 . nr % 0
50 . nr F 2
51 . \}
52 . \}
53 .\}
54 .rr rF
55 .\"
56 .\" Required to disable full justification in groff 1.23.0.
57 .if n .ds AD l
58 .\" ========================================================================
59 .\"
60 .IX Title "RPMORPHAN 1"
61 .TH RPMORPHAN 1 2026-01-17 "perl v5.42.0" "User Contributed Perl Documentation"
62 .\" For nroff, turn off justification. Always turn off hyphenation; it makes
63 .\" way too many mistakes in technical documents.
64 .if n .ad l
65 .nh
66 .SH NAME
67 rpmorphan \- find orphaned packages
68 .SH DESCRIPTION
69 .IX Header "DESCRIPTION"
70 rpmorphan finds "orphaned" packages on your system. It determines which packages have no other
71 packages depending on their installation, and shows you a list of these packages.
72 It is clone of deborphan debian software for rpm packages.
73 .PP
74 It will try to help you to remove unused packages, for exemple :
75 .PP
76 \&\- after a distribution upgrade
77 .PP
78 \&\- when you want to suppress packages after some tests
79 .SH SYNOPSIS
80 .IX Header "SYNOPSIS"
81 rpmorphan [options] [targets]
82 .PP
83 or
84 .PP
85 grpmorphan [options] [targets]
86 .PP
87 using grpmorphan is a short way to use "rpmorphan \-gui"
88 .PP
89 options:
90 .PP
91 .Vb 3
92 \& \-help brief help message
93 \& \-man full documentation
94 \& \-V, \-\-version print version
95 \&
96 \& \-verbose verbose
97 \& \-debug debug mode (for developpers only)
98 \& \-dry\-run simulate package remove
99 \& \-fullalgo force full algorythm
100 \& \-suggests use suggested package as if required
101 \& \-recommends use recommends package as if required
102 \& \-arch work and show on full name with version and architecture
103 \& \-log\-file mylog change default log file to mylog
104 \& \-use\-cache use cache to avoid rpm query
105 \& \-clear\-cache remove cache file
106 \& \-gui display the graphical interface
107 \& \-tk display the tk graphical interface
108 \& \-curses display the curses graphical interface
109 \&
110 \& \-exclude pac exclude pac from results
111 \& \-install\-time +/\-d apply on packages which are installed before (after) d days
112 \& \-access\-time d apply on packages which are not been accessed for d days (slow)
113 .Ve
114 .PP
115 targets:
116 .PP
117 .Vb 10
118 \& \-package pac search if pac is an orphan package
119 \& \-all apply on all packages
120 \& \-guess\-perl apply on perl packages
121 \& \-guess\-python apply on python packages
122 \& \-guess\-pike apply on pike packages
123 \& \-guess\-ruby apply on ruby packages
124 \& \-guess\-common apply on common packages
125 \& \-guess\-data apply on data packages
126 \& \-guess\-doc apply on documentation packages
127 \& \-guess\-dev apply on development packages
128 \& \-guess\-lib apply on library packages (this is the default target if none is specified)
129 \& \-guess\-all apply all \-guess\-* options (perl, python ...)
130 \& \-guess\-custom regex apply the given regex to filter to package\*(Aqs names to filter the output
131 .Ve
132 .PP
133 keep file management
134 .PP
135 .Vb 5
136 \& \-keep\-file file define the keep file to be used
137 \& \-list\-keep list permanent exclude list
138 \& \-zero\-keep empty permanent exclude list
139 \& \-add\-keep pac add pac package to permanent exclude list
140 \& \-del\-keep pac remove pac package from permanent exclude list
141 .Ve
142 .SH "REQUIRED ARGUMENTS"
143 .IX Header "REQUIRED ARGUMENTS"
144 you should provide at least one target. this can be
145 .IP \fB\-all\fR 8
146 .IX Item "-all"
147 all the installed rpm package
148 .IP \fB\-package\fR 8
149 .IX Item "-package"
150 one or several explicit package
151 .IP \fB\-guess\-*\fR 8
152 .IX Item "-guess-*"
153 pre\-selected packages groups
154 .IP \fB\-guess\-custom\fR 8
155 .IX Item "-guess-custom"
156 give a filter to select the packages you want study. you can use regular expressions.
157 .SH OPTIONS
158 .IX Header "OPTIONS"
159 .IP \fB\-help\fR 8
160 .IX Item "-help"
161 Print a brief help message and exits.
162 .IP \fB\-man\fR 8
163 .IX Item "-man"
164 Print the manual page and exits.
165 .IP \fB\-version\fR 8
166 .IX Item "-version"
167 Print the program release and exit.
168 .IP \fB\-verbose\fR 8
169 .IX Item "-verbose"
170 The program works and print debugging messages.
171 .IP \fB\-debug\fR 8
172 .IX Item "-debug"
173 for developpers, the program will dump internals structures
174 .IP \fB\-dry\-run\fR 8
175 .IX Item "-dry-run"
176 this is a simulation mode : rpmorphan will show you what is
177 the result of package removing. The window\*(Aqs title is modified
178 to show this mode.
179 .IP \fB\-use\-cache\fR 8
180 .IX Item "-use-cache"
181 the rpm query may be long (10 to 30 s). If you will run an rpmorphan tool
182 several time, this option will allow to gain a lot of time :
183 it save the rpm query on a file cache (first call), then
184 use this cache instead quering rpm (others calls).
185 .IP \fB\-clear\-cache\fR 8
186 .IX Item "-clear-cache"
187 to remove cache file. Can be used with \-use\-cache to write
188 a new cache.
189 .IP \fB\-gui\fR 8
190 .IX Item "-gui"
191 display a graphical interface which allow to show informations, remove packages
192 (an internal help is provided). This is currently the same as the \-tk option
193 .IP \fB\-tk\fR 8
194 .IX Item "-tk"
195 display a tk graphical interface which allow to show informations, remove packages
196 (an internal help is provided). The Tk perl module is necessary to run the gui.
197 .IP \fB\-curses\fR 8
198 .IX Item "-curses"
199 display a curses graphical interface which allow to show informations, remove packages
200 (an internal help is provided). The Curses::UI perl module is necessary to run the gui.
201 .IP \fB\-exclude\fR 8
202 .IX Item "-exclude"
203 this option will specify the packages to exclude from the output.
204 Can be used as \*(Aq\-\-exclude pac1 \-\-exclude pac2\*(Aq
205 or \*(Aq\-\-exclude "pac1, pac2"\*(Aq
206 .IP \fB\-install\-time\fR 8
207 .IX Item "-install-time"
208 install\-time is a filter on the period from the package installation date to now (in days).
209 if set positive, it only allow packages installed before x days.
210 if set negative, it only allow packages installed since x days.
211 .IP \fB\-access\-time\fR 8
212 .IX Item "-access-time"
213 access\-time is designed to filter packages which have not been used since x days.
214 .Sp
215 be careful : this option will slow the program
216 .IP \fB\-fullalgo\fR 8
217 .IX Item "-fullalgo"
218 for a small list of packages, rpmorphan use a different quicker methode : rpm \-e \-\-test
219 .Sp
220 this option can be used to force the use of the full algo
221 .IP \fB\-suggests\fR 8
222 .IX Item "-suggests"
223 some rpm version offers a meta\-data dependency call suggests : it is
224 for usefull but not necessary packages (very weak dependency). if this option is set, the
225 suggested packages are used in rpmorphan as required packages.
226 The default value for this option is unset.
227 .IP \fB\-recommends\fR 8
228 .IX Item "-recommends"
229 some rpm version offers a meta\-data dependency call recommends : it is
230 for usefull but not necessary packages(weak dependency). if this option is set, the
231 recommended packages are used in rpmorphan as required packages.
232 The default value for this option is unset.
233 .IP \fB\-arch\fR 8
234 .IX Item "-arch"
235 by default, rpmorphan works on package name. this option will rpmorphan work
236 on full package name : name\-version\-release.arch.
237 This may be usefull if you have several version or several archictectures installed.
238 .IP \fB\-log\-file\fR 8
239 .IX Item "-log-file"
240 change the default log file (/var/log/rpmorphan.log) to the given file name
241 .IP \fB\-package\fR 8
242 .IX Item "-package"
243 search if the given package(s) is(are) orphaned.
244 Can be used as \*(Aq\-\-package pac1 \-\-package pac2\*(Aq
245 or \*(Aq\-\-package "pac1, pac2"\*(Aq
246 .IP \fB\-all\fR 8
247 .IX Item "-all"
248 apply on all installed packages. The output should be interpreted.
249 For example lilo or grub are orphaned packages, but are necessary
250 to boot ...
251 .Sp
252 the "\-install\-time" and "\-access\-time" options may be useful to filter the list
253 .IP \fB\-guess\-perl\fR 8
254 .IX Item "-guess-perl"
255 This option tries to find perl modules. It tries to match "^perl"
256 .IP \fB\-guess\-python\fR 8
257 .IX Item "-guess-python"
258 This option tries to find python modules. It tries to match "^python"
259 .IP \fB\-guess\-pike\fR 8
260 .IX Item "-guess-pike"
261 This option tries to find pike modules. It tries to match "^pike"
262 .IP \fB\-guess\-ruby\fR 8
263 .IX Item "-guess-ruby"
264 This option tries to find ruby modules. It tries to match "^ruby"
265 .IP \fB\-guess\-common\fR 8
266 .IX Item "-guess-common"
267 This option tries to find common packages. It tries to match "\-common$"
268 .IP \fB\-guess\-data\fR 8
269 .IX Item "-guess-data"
270 This option tries to find data packages. It tries to match "\-data$"
271 .IP \fB\-guess\-doc\fR 8
272 .IX Item "-guess-doc"
273 This option tries to find documentation packages. It tries to match "\-doc$"
274 .IP \fB\-guess\-data\fR 8
275 .IX Item "-guess-data"
276 This option tries to find data packages. It tries to match "\-data$"
277 .IP \fB\-guess\-dev\fR 8
278 .IX Item "-guess-dev"
279 This option tries to find development packages. It tries to match "\-devel$"
280 .IP \fB\-guess\-lib\fR 8
281 .IX Item "-guess-lib"
282 This option tries to find library packages. It tries to match "^lib"
283 .IP \fB\-guess\-all\fR 8
284 .IX Item "-guess-all"
285 This is a short to tell : Try all of the above (perl, python ...)
286 .IP \fB\-guess\-custom\fR 8
287 .IX Item "-guess-custom"
288 this will allow you to specify your own filter. for exemple "^wh"
289 will match whois, whatsnewfm ...
290 .IP \fB\-keep\-file\fR 8
291 .IX Item "-keep-file"
292 define the keep file to be used. If not set, the /var/lib/rpmorphan/keep will be used
293 .IP \fB\-list\-keep\fR 8
294 .IX Item "-list-keep"
295 list the permanent list of excluded packages and exit.
296 .IP \fB\-zero\-keep\fR 8
297 .IX Item "-zero-keep"
298 empty the permanent list of excluded packages and exit.
299 .IP \fB\-add\-keep\fR 8
300 .IX Item "-add-keep"
301 add package(s) to the permanent list of excluded packages and exit.
302 .Sp
303 Can be used as \*(Aq\-\-add\-keep pac1 \-\-add\-keep pac2\*(Aq
304 or \*(Aq\-\-add\-keep "pac1, pac2"\*(Aq
305 .IP \fB\-del\-keep\fR 8
306 .IX Item "-del-keep"
307 remove package(s) from the permanent list of excluded packages and exit.
308 .Sp
309 Can be used as \*(Aq\-\-add\-keep pac1 \-\-add\-keep pac2\*(Aq
310 or \*(Aq\-\-add\-keep "pac1, pac2"\*(Aq
311 .SH USAGE
312 .IX Header "USAGE"
313 rpmorphan can be useful after a distribution upgrade, to remove packages forgotten
314 by the upgrade tool. It is interesting to use the options "\-all \-install\-time +xx\*(Aq.
315 .PP
316 If you want to remove some recent tested packages, my advice is "\-all \-install\-time \-xx\*(Aq.
317 .PP
318 if you just want to clean your disk, use \*(Aq\-all \-access\-time xxx\*(Aq
319 .SH FILES
320 .IX Header "FILES"
321 /var/lib/rpmorphan/keep : the permanent exclude list
322 .PP
323 /tmp/rpmorphan.cache : cache file to store rpm query. The cache
324 file is common to all rpmorphan tools
325 .PP
326 /var/log/rpmorphan.log : log of all deleted packages
327 .SH CONFIGURATION
328 .IX Header "CONFIGURATION"
329 the program can read rcfile if some exists.
330 it will load in order
331 .PP
332 /etc/rpmorphanrc
333 .PP
334 ~/.rpmorphanrc
335 .PP
336 \&.rpmorphanrc
337 .PP
338 In this file,
339 .PP
340 # are comments,
341 .PP
342 and parameters are stored in the following format :
343 parameter = value
344 .PP
345 example :
346 .PP
347 all = 1
348 .PP
349 curses = 1
350 .SH DEPENDENCIES
351 .IX Header "DEPENDENCIES"
352 rpmorphan uses standard perl module in console mode.
353 .PP
354 If you want to use the Tk graphical interface, you should install the Tk module
355 (perl\-Tk rpm package).
356 .PP
357 If you want to use the curses interface, you should install the Curses::UI perl module
358 ( perl\-Curses\-UI rpm package).
359 .PP
360 If you want to speed up rpmorphan, you should install the RPM2 perl module ( perl\-RPM2 rpm package).
361 On mandriva, the URPM perl module (dependency from urpmi) will be used instead.
362 .SH EXAMPLES
363 .IX Header "EXAMPLES"
364 .IP "display orphaned libraries" 8
365 .IX Item "display orphaned libraries"
366 rpmorphan
367 .IP "display all orphaned packages in a curses interface" 8
368 .IX Item "display all orphaned packages in a curses interface"
369 rpmorphan \-\-all \-\-curses
370 .IP "display orphaned packages, not used since one year" 8
371 .IX Item "display orphaned packages, not used since one year"
372 rpmorphan \-\-all \-access\-time +365
373 .IP "display all orphaned packages, installed in the last 10 days" 8
374 .IX Item "display all orphaned packages, installed in the last 10 days"
375 rpmorphan \-\-all \-install\-time \-10
376 .IP "display all orphaned packages, installed one month ago (or more)" 8
377 .IX Item "display all orphaned packages, installed one month ago (or more)"
378 rpmorphan \-\-all \-install\-time +30
379 .IP "display orphaned packages but not weak dependencies" 8
380 .IX Item "display orphaned packages but not weak dependencies"
381 rpmorphan \-\-all \-\-recommends
382 .IP "display orphaned packages but not all weak dependencies" 8
383 .IX Item "display orphaned packages but not all weak dependencies"
384 rpmorphan \-\-all \-\-recommends \-\-suggests
385 .SH "BUGS AND LIMITATIONS"
386 .IX Header "BUGS AND LIMITATIONS"
387 Virtuals packages are not well (for now) taken in account.
388 Let\*(Aqs see an example : lilo and grub provide \*(Aqbootloader\*(Aq virtual, which is
389 necessary for system boot.
390 if the 2 are installed, they will be shown all 2 as orphans (but you can not remove
391 the 2).
392 If you remove one of them, the other is now longer shown as orphan.
393 .PP
394 the software can only work with one version of each software :
395 we only treat the first version seen
396 .PP
397 the code does not use the following rpm tags : Supplements, Enhances
398 .SH INCOMPATIBILITIES
399 .IX Header "INCOMPATIBILITIES"
400 not known
401 .SH DIAGNOSTICS
402 .IX Header "DIAGNOSTICS"
403 to be written
404 .SH NOTES
405 .IX Header "NOTES"
406 this program can be used as "normal" user to show orphans,
407 but you need to run it as supersuser (root) to remove packages
408 or apply changes in the permanent exclude list
409 .PP
410 access\-time and install\-time options are "new" features, not available
411 in deborphan tool
412 .PP
413 For Fedora users :
414 Yum offers a program called \*(Aqpackage\-cleanup\*(Aq which,
415 called with the \*(Aq\-\-leaves\*(Aq option, can show quickly a list of
416 unused library packages.
417 .PP
418 For Mandriva users :
419 the \*(Aqurpme \-\-auto\-orphans\*(Aq command show quickly a a list of
420 unused library packages.
421 .SH ENVIRONMENT
422 .IX Header "ENVIRONMENT"
423 .IP RPMORPHAN_METHOD 8
424 .IX Item "RPMORPHAN_METHOD"
425 for experts only : allow to force the method used to get rpm
426 data. It can be set to URPM, RPM2 or \*(Aqbasic\*(Aq (for external rpm query)
427 .SH "SEE ALSO"
428 .IX Header "SEE ALSO"
429 \fIrpm\fR\|(1) for rpm call
430 .PP
431 \fIrpmusage\fR\|(1)
432 .PP
433 \fIrpmdep\fR\|(1)
434 .PP
435 \fIrpmduplicates\fR\|(1)
436 .PP
437 \fIrpmextra\fR\|(1)
438 .SH "EXIT STATUS"
439 .IX Header "EXIT STATUS"
440 should be allways 0
441 .SH "LICENSE AND COPYRIGHT"
442 .IX Header "LICENSE AND COPYRIGHT"
443 Copyright (C) 2006 by Eric Gerbier
444 This program is free software; you can redistribute it and/or modify
445 it under the terms of the GNU General Public License as published by
446 the Free Software Foundation; either version 2 of the License, or
447 (at your option) any later version.
448 .SH AUTHOR
449 .IX Header "AUTHOR"
450 Eric Gerbier
451 .PP
452 you can report any bug or suggest to [email protected]