source: yum/trunk/docs/yum.8@ 6

Last change on this file since 6 was 2, checked in by Yuri Dario, 15 years ago

Initial import for vendor code.

  • Property svn:eol-style set to native
File size: 22.0 KB
Line 
1.\" yum - Yellowdog Updater Modified
2.TH "yum" "8" "" "Seth Vidal" ""
3.SH "NAME"
4yum \- Yellowdog Updater Modified
5.SH "SYNOPSIS"
6\fByum\fP [options] [command] [package ...]
7.SH "DESCRIPTION"
8.PP
9\fByum\fP is an interactive, rpm based, package manager. It can automatically
10perform system updates, including dependency analysis and obsolete processing
11based on "repository" metadata. It can also perform installation of new
12packages, removal of old packages and perform queries on the installed and/or
13available packages among many other commands/services (see below)\&. \fByum\fP
14is similar to other high level package managers like apt\-get and smart\&.
15.PP
16While there are some graphical interfaces directly to the \fByum\fP code, more
17recent graphical interface development is happening with PackageKit and the
18gnome\-packagekit application\&.
19.PP
20\fIcommand\fP is one of:
21.br
22.I \fR * install package1 [package2] [\&.\&.\&.]
23.br
24.I \fR * update [package1] [package2] [\&.\&.\&.]
25.br
26.I \fR * check\-update
27.br
28.I \fR * upgrade [package1] [package2] [\&.\&.\&.]
29.br
30.I \fR * remove | erase package1 [package2] [\&.\&.\&.]
31.br
32.I \fR * list [\&.\&.\&.]
33.br
34.I \fR * info [\&.\&.\&.]
35.br
36.I \fR * provides | whatprovides feature1 [feature2] [\&.\&.\&.]
37.br
38.I \fR * clean [ packages | metadata | expire-cache | rpmdb | plugins | all ]
39.br
40.I \fR * makecache
41.br
42.I \fR * groupinstall group1 [group2] [\&.\&.\&.]
43.br
44.I \fR * groupupdate group1 [group2] [\&.\&.\&.]
45.br
46.I \fR * grouplist [hidden] [groupwildcard] [\&.\&.\&.]
47.br
48.I \fR * groupremove group1 [group2] [\&.\&.\&.]
49.br
50.I \fR * groupinfo group1 [\&.\&.\&.]
51.br
52.I \fR * search string1 [string2] [\&.\&.\&.]
53.br
54.I \fR * shell [filename]
55.br
56.I \fR * resolvedep dep1 [dep2] [\&.\&.\&.]
57.br
58.I \fR * localinstall rpmfile1 [rpmfile2] [\&.\&.\&.]
59.br
60.I \fR * localupdate rpmfile1 [rpmfile2] [\&.\&.\&.]
61.br
62.I \fR * reinstall package1 [package2] [\&.\&.\&.]
63.br
64.I \fR * downgrade package1 [package2] [\&.\&.\&.]
65.br
66.I \fR * deplist package1 [package2] [\&.\&.\&.]
67.br
68.I \fR * repolist [all|enabled|disabled]
69.br
70.I \fR * version [all|installed|available|group-*|grouplist|groupinfo]
71.br
72.I \fR * history [info|list|summary|redo|undo|new]
73.br
74.I \fR * check
75.br
76.I \fR * help [command]
77.br
78.PP
79Unless the \-\-help or \-h option is given, one of the above commands
80must be present\&.
81.PP
82Repository configuration is honored in all operations.
83.PP
84.IP "\fBinstall\fP"
85Is used to install the latest version of a package or
86group of packages while ensuring that all dependencies are
87satisfied\&. (See \fBSpecifying package names\fP for more information)
88If no package matches the given package name(s), they are assumed to be a shell
89glob and any matches are then installed\&. If the name starts with an
90@ character the rest of the name is used as though passed to the groupinstall command\&. If the name is a file, then install works
91like localinstall\&. If the name doesn't match a package, then package
92"provides" are searched (Eg. "_sqlitecache.so()(64bit)") as are
93filelists (Eg. "/usr/bin/yum"). Also note that for filelists, wildcards will
94match multiple packages\&.
95.IP
96.IP "\fBupdate\fP"
97If run without any packages, update will update every currently
98installed package. If one or more packages or package globs are specified, Yum will
99only update the listed packages\&. While updating packages, \fByum\fP
100will ensure that all dependencies are satisfied\&. (See \fBSpecifying package names\fP for more information)
101If the packages or globs specified match to packages which are not currently installed then update will
102not install them\&. update operates on groups, files, provides and filelists
103just like the "install" command\&.
104
105If the main obsoletes configure option is true (default) or the \-\-obsoletes
106flag is present \fByum\fP will include package
107obsoletes in its calculations - this makes it better for distro\-version
108changes, for example: upgrading from somelinux 8.0 to somelinux 9.
109.IP
110.IP "\fBcheck\-update\fP"
111Implemented so you could know if your machine had any updates that needed to
112be applied without running it interactively. Returns exit value of 100 if
113there are packages available for an update. Also returns a list of the packages
114to be updated in list format. Returns 0 if no packages are available for
115update. Returns 1 if an error occurred.
116Running in verbose mode also shows obsoletes.
117.IP
118.IP "\fBupgrade\fP"
119Is the same as the update command with the \-\-obsoletes flag set. See update
120for more details.
121.IP
122.IP "\fBremove\fP or \fBerase\fP"
123Are used to remove the specified packages from the system
124as well as removing any packages which depend on the package being
125removed\&. remove operates on groups, files, provides and filelists just like
126the "install" command\&.(See \fBSpecifying package names\fP for more information)
127.IP
128.IP "\fBlist\fP"
129Is used to list various information about available
130packages; more complete details are available in the \fIList Options\fP
131section below\&.
132.IP
133.IP "\fBprovides\fP or \fBwhatprovides\fP"
134Is used to find out which package provides some feature
135or file. Just use a specific name or a file-glob-syntax wildcards to list
136the packages available or installed that provide that feature or file\&.
137.IP
138.IP "\fBsearch\fP"
139Is used to find any packages matching a string in the description, summary
140and package name fields of an rpm. Useful for finding a package
141you do not know by name but know by some word related to it.
142.IP
143.IP "\fBinfo\fP"
144Is used to list a description and summary information about available
145packages; takes the same arguments as in the \fIList Options\fP
146section below\&.
147.IP
148.IP "\fBclean\fP"
149Is used to clean up various things which accumulate in the
150\fByum\fP cache directory over time. More complete details can be found in
151the \fIClean Options\fP section below\&.
152.IP
153.IP "\fBmakecache\fP"
154Is used to download and make usable all the metadata for the currently enabled
155\fByum\fP repos.
156.IP
157.IP "\fBgroupinstall\fP"
158Is used to install all of the individual packages in a group, of the specified
159types (this works as if you'd taken each of those package names and put them on
160the command line for a "yum install" command).
161 The group_package_types configuration option specifies which types will
162be installed.
163.IP
164.IP "\fBgroupupdate\fP"
165Is just an alias for groupinstall, which will do the right thing because
166"yum install X" and "yum update X" do the same thing, when X is already
167installed.
168.IP
169.IP "\fBgrouplist\fP"
170Is used to list the available groups from all \fByum\fP repos. Groups are marked
171as "installed" if all mandatory packages are installed, or if a group doesn't
172have any mandatory packages then it is installed if any of the optional or
173default package are installed.
174The optional "hidden" argument will also list groups marked as not being
175"user visible". If you pass the \-v option, to enable verbose mode, then the
176groupids are displayed.
177.IP
178.IP "\fBgroupremove\fP"
179Is used to remove all of the packages in a group, unlike "groupinstall" this
180will remove everything regardless of group_package_types. It is worth pointing
181out that packages can be in more than one group, so "groupinstall X Y" followed
182by "groupremove Y" does not do give you the same result as "groupinstall X".
183.IP
184.IP "\fBgroupinfo\fP"
185Is used to give the description and package list of a group (and which type
186those packages are marked as). Note that you can use the yum-filter-data and
187yum-list-data plugins to get/use the data the other way around (Ie. what
188groups own packages need updating). If you pass the \-v option, to enable verbose
189mode, then the package names are matched against installed/available packages
190similar to the list command.
191.IP
192.IP "\fBshell\fP"
193Is used to enter the 'yum shell', when a filename is specified the contents of
194that file is executed in yum shell mode. See \fIyum-shell(8)\fP for more info
195.IP
196.IP "\fBresolvedep\fP"
197Is used to list packages providing the specified dependencies, at most one
198package is listed per dependency.
199.IP
200.IP "\fBlocalinstall\fP"
201Is used to install a set of local rpm files. If required the enabled
202repositories will be used to resolve dependencies. Note that the install command
203will do a local install, if given a filename.
204.IP
205.IP "\fBlocalupdate\fP"
206Is used to update the system by specifying local rpm files. Only the specified
207rpm files of which an older version is already installed will be installed,
208the remaining specified packages will be ignored.
209If required the enabled repositories will be used to resolve dependencies. Note
210that the update command will do a local install, if given a filename.
211.IP
212.IP "\fBreinstall\fP"
213Will reinstall the identically versioned package as is currently installed.
214This does not work for "installonly" packages, like Kernels. reinstall operates
215on groups, files, provides and filelists just like the "install" command\&.
216.IP
217.IP "\fBdowngrade\fP"
218Will try and downgrade a package from the version currently installed to the
219previously highest version (or the specified version).
220The depsolver will not necessarily work, but if you specify all the packages it
221should work (and thus. all the simple cases will work). Also this does not
222work for "installonly" packages, like Kernels. downgrade operates
223on groups, files, provides and filelists just like the "install" command\&.
224.IP
225.IP "\fBdeplist\fP"
226Produces a list of all dependencies and what packages provide those
227dependencies for the given packages.
228.IP
229.IP "\fBrepolist\fP"
230Produces a list of configured repositories. The default is to list all
231enabled repositories. If you pass \-v, for verbose mode, more information is
232listed. If the first argument is 'enabled', 'disabled' or 'all' then the command
233will list those types of repos.
234
235You can pass repo id or name arguments, or wildcards which to match against
236both of those. However if the ir or name matches exactly then the repo will
237be listed even if you are listing enabled repos. and it is disabled.
238
239In non-verbose mode the first column will start with a '*' if the repo. has
240metalink data and the latest metadata is not local. For non-verbose mode the
241last column will also display the number of packages in the repo. and (if there
242are any user specified excludes) the number of packages excluded.
243
244One last special feature of repolist, is that if you are in non-verbose mode
245then yum will ignore any repo errors and output the information it can get
246(Eg. "yum clean all; yum -C repolist" will output something, although the
247package counts/etc. will be zeroed out).
248.IP
249.IP "\fBversion\fP"
250Produces a "version" of the rpmdb, and of the enabled repositories if "all" is
251given as the first argument. You can also specify version groups in the
252version-groups config. file. If you pass \-v, for verbose mode, more
253information is listed. The version is calculated by taking a sha1 hash of the
254packages (in sorted order), and the checksum_type/checksum_data entries from
255the yumdb. Note that this rpmdb version is now also used significantly within
256yum (esp. in yum history).
257.IP
258.IP "\fBhistory\fP"
259The history command allows the user to view what has happened in past
260transactions (assuming the history_record config. option is set). You can use
261info/list/summary to view what happened, undo/redo to act on that information
262and new to start a new history file.
263
264The info/list/summary commands take either a transaction id or a package (with
265wildcards, as in \fBSpecifying package names\fP), all three can also be passed
266no arguments. list can be passed the keyword "all" to list all the transactions.
267
268The undo/redo commands take either a transaction id or the keyword last and
269an offset from the last transaction (Eg. if you've done 250 transactions,
270"last" refers to transaction 250, and "last-4" refers to transaction 246).
271
272In "history list" output the Altered column also gives some extra information
273if there was something not good with the transaction.
274
275.I \fB>\fR - The rpmdb was changed, outside yum, after the transaction.
276.br
277.I \fB<\fR - The rpmdb was changed, outside yum, before the transaction.
278.br
279.I \fB*\fR - The transaction aborted before completion.
280.br
281.I \fB#\fR - The transaction completed, but with a non-zero status.
282.br
283
284.IP
285.IP "\fBcheck\fP"
286Checks the local rpmdb and produces information on any problems it finds. You
287can pass the check command the arguments "dependencies" or "duplicates", to
288limit the checking that is performed (the default is "all" which does both).
289.IP
290.IP "\fBhelp\fP"
291Produces help, either for all commands or if given a command name then the help
292for that particular command\&.
293.IP
294.PP
295.SH "GENERAL OPTIONS"
296Most command line options can be set using the configuration file as
297well and the descriptions indicate the necessary configuration option
298to set\&.
299.PP
300.IP "\fB\-h, \-\-help\fP"
301Help; display a help message and then quit\&.
302.IP "\fB\-y, \-\-assumeyes\fP"
303Assume yes; assume that the answer to any question which would be asked
304is yes\&.
305.br
306Configuration Option: \fBassumeyes\fP
307.IP "\fB\-c, \-\-config=[config file]\fP"
308Specifies the config file location - can take HTTP and FTP URLs and local file
309paths\&.
310.br
311.IP "\fB\-q, \-\-quiet\fP"
312Run without output. Note that you likely also want to use \-y\&.
313.br
314.IP "\fB\-v, \-\-verbose\fP"
315Run with a lot of debugging output\&.
316.br
317.IP "\fB\-d, \-\-debuglevel=[number]\fP"
318Sets the debugging level to [number] \- turns up or down the amount of things that are printed\&. Practical range: 0 - 10
319.br
320Configuration Option: \fBdebuglevel\fP
321.IP "\fB\-e, \-\-errorlevel=[number]\fP"
322Sets the error level to [number] Practical range 0 \- 10. 0 means print only critical errors about which you must be told. 1 means print all errors, even ones that are not overly important. 1+ means print more errors (if any) \-e 0 is good for cron jobs.
323.br
324Configuration Option: \fBerrorlevel\fP
325.IP "\fB\-\-rpmverbosity=[name]\fP"
326Sets the debug level to [name] for rpm scriplets. 'info' is the default, other
327options are: 'critical', 'emergency', 'error', 'warn' and 'debug'.
328.br
329Configuration Option: \fBrpmverbosity\fP
330.IP "\fB\-R, \-\-randomwait=[time in minutes]\fP"
331Sets the maximum amount of time yum will wait before performing a command \- it randomizes over the time.
332.IP "\fB\-C, \-\-cacheonly\fP"
333Tells yum to run entirely from system cache - does not download or
334update any headers unless it has to to perform the requested action.
335.IP "\fB\-\-version\fP"
336Reports the \fByum\fP version number and installed package versions for
337everything in history_record_packages (can be added to by plugins).
338.IP "\fB\-\-showduplicates\fP"
339Doesn't limit packages to their latest versions in the info, list and search
340commands (will also affect plugins which use the doPackageLists() API).
341.IP "\fB\-\-installroot=root\fP"
342Specifies an alternative installroot, relative to which all packages will be
343installed.
344.br
345Configuration Option: \fBinstallroot\fP
346.IP "\fB\-\-enablerepo=repoidglob\fP"
347Enables specific repositories by id or glob that have been disabled in the
348configuration file using the enabled=0 option.
349.br
350Configuration Option: \fBenabled\fP
351.IP "\fB\-\-disablerepo=repoidglob\fP"
352Disables specific repositories by id or glob.
353.br
354Configuration Option: \fBenabled\fP
355.IP "\fB\-\-obsoletes\fP"
356This option only has affect for an update, it enables \fByum\fP\'s obsoletes
357processing logic. For more information see the \fBupdate\fP command above.
358.br
359Configuration Option: \fBobsoletes\fP
360.IP "\fB\-x, \-\-exclude=package\fP"
361Exclude a specific package by name or glob from updates on all repositories.
362Configuration Option: \fBexclude\fP
363.br
364.IP "\fB\-\-color=[always|auto|never]\fP"
365Display colorized output automatically, depending on the output terminal,
366always (using ANSI codes) or never. Note that some commands (Eg. list and info)
367will do a little extra work when color is enabled.
368Configuration Option: \fBcolor\fP
369.br
370.IP "\fB\-\-disableexcludes=[all|main|repoid]\fP"
371Disable the excludes defined in your config files. Takes one of three options:
372.br
373all == disable all excludes
374.br
375main == disable excludes defined in [main] in yum.conf
376.br
377repoid == disable excludes defined for that repo
378.br
379.IP "\fB\-\-disableplugin=plugin\fP"
380Run with one or more plugins disabled, the argument is a comma separated list
381of wildcards to match against plugin names.
382.br
383.IP "\fB\-\-noplugins\fP"
384Run with all plugins disabled.
385.br
386Configuration Option: \fBplugins\fP
387.IP "\fB\-\-nogpgcheck\fP"
388Run with GPG signature checking disabled.
389.br
390Configuration Option: \fBgpgcheck\fP
391.IP "\fB\-\-skip\-broken\fP"
392Resolve depsolve problems by removing packages that are causing problems
393from the transaction.
394.br
395Configuration Option: \fBskip_broken\fP
396.br
397.IP "\fB\-\-releasever=version\fP"
398Pretend the current release version is the given string. This is very useful
399when combined with \-\-installroot. Note that with the default upstream cachedir,
400of /var/cache/yum, using this option will corrupt your cache (and you can use
401$releasever in your cachedir configuration to stop this).
402.PP
403.IP "\fB\-t, \-\-tolerant\fP"
404This option currently does nothing.
405.br
406.SH "LIST OPTIONS"
407The following are the ways which you can invoke \fByum\fP in list
408mode\&. Note that all \fBlist\fP commands include information on the
409version of the package\&.
410.IP
411.IP "\fBOUTPUT\fP"
412
413
414The format of the output of yum list is:
415
416name.arch [epoch:]version-release repo or \@installed-from-repo
417
418.IP "\fByum list [all | glob_exp1] [glob_exp2] [\&.\&.\&.]\fP"
419List all available and installed packages\&.
420.IP "\fByum list available [glob_exp1] [\&.\&.\&.]\fP"
421List all packages in the yum repositories available to be installed\&.
422.IP
423.IP "\fByum list updates [glob_exp1] [\&.\&.\&.]\fP"
424List all packages with updates available in the yum repositories\&.
425.IP
426.IP "\fByum list installed [glob_exp1] [\&.\&.\&.]\fP"
427List the packages specified by \fIargs\fP\&. If an argument does not
428match the name of an available package, it is assumed to be a
429shell\-style glob and any matches are printed\&.
430.IP
431.IP "\fByum list extras [glob_exp1] [\&.\&.\&.]\fP"
432List the packages installed on the system that are not available in any yum
433repository listed in the config file.
434.IP
435.IP "\fByum list obsoletes [glob_exp1] [\&.\&.\&.]\fP"
436List the packages installed on the system that are obsoleted by packages
437in any yum repository listed in the config file.
438.IP
439.IP "\fByum list recent\fP"
440List packages recently added into the repositories. This is often not helpful,
441but what you may really want to use is "yum list-updateinfo new" from the
442security yum plugin.
443.IP
444
445.PP
446.SH "SPECIFYING PACKAGE NAMES"
447A package can be referred to for install, update, remove, list, info etc
448with any of the following as well as globs of any of the following:
449.IP
450.br
451\fBname\fP
452.br
453\fBname.arch\fP
454.br
455\fBname-ver\fP
456.br
457\fBname-ver-rel\fP
458.br
459\fBname-ver-rel.arch\fP
460.br
461\fBname-epoch:ver-rel.arch\fP
462.br
463\fBepoch:name-ver-rel.arch\fP
464.IP
465For example: \fByum remove kernel-2.4.1-10.i686\fP
466 this will remove this specific kernel-ver-rel.arch.
467.IP
468Or: \fByum list available 'foo*'\fP
469 will list all available packages that match 'foo*'. (The single quotes will keep your shell from expanding the globs.)
470.IP
471.PP
472.SH "CLEAN OPTIONS"
473The following are the ways which you can invoke \fByum\fP in clean
474mode. Note that "all files" in the commands below means
475"all files in currently enabled repositories".
476If you want to also clean any (temporarily) disabled repositories you need to
477use \fB\-\-enablerepo='*'\fP option.
478
479.IP "\fByum clean expire-cache\fP"
480Eliminate the local data saying when the metadata and mirrorlists were downloaded for each repo. This means yum will revalidate the cache for each repo. next time it is used. However if the cache is still valid, nothing significant was deleted.
481
482.IP "\fByum clean packages\fP"
483Eliminate any cached packages from the system. Note that packages are not automatically deleted after they are downloaded.
484
485.IP "\fByum clean headers\fP"
486Eliminate all of the header files, which old versions of yum used for
487dependency resolution.
488
489.IP "\fByum clean metadata\fP"
490Eliminate all of the files which yum uses to determine the remote
491availability of packages. Using this option will force yum to download all the
492metadata the next time it is run.
493
494.IP "\fByum clean dbcache\fP"
495Eliminate the sqlite cache used for faster access to metadata.
496Using this option will force yum to download the sqlite metadata the next time
497it is run, or recreate the sqlite metadata if using an older repo.
498
499.IP "\fByum clean dbcache\fP"
500Eliminate the sqlite cache used for faster access to metadata.
501Using this option will force yum to download the sqlite metadata the next time
502it is run, or recreate the sqlite metadata if using an older repo.
503
504.IP "\fByum clean rpmdb\fP"
505Eliminate any cached data from the local rpmdb.
506
507.IP "\fByum clean plugins\fP"
508Tell any enabled plugins to eliminate their cached data.
509
510.IP "\fByum clean all\fP"
511Does all of the above.
512
513.PP
514.SH "PLUGINS"
515Yum can be extended through the use of plugins. A plugin is a Python ".py" file
516which is installed in one of the directories specified by the \fBpluginpath\fP
517option in yum.conf. For a plugin to work, the following conditions must be met:
518.LP
5191. The plugin module file must be installed in the plugin path as just
520described.
521.LP
5222. The global \fBplugins\fP option in /etc/yum/yum.conf must be set to `1'.
523.LP
5243. A configuration file for the plugin must exist in
525/etc/yum/pluginconf.d/<plugin_name>.conf and the \fBenabled\fR setting in this
526file must set to `1'. The minimal content for such a configuration file is:
527.IP
528[main]
529.br
530enabled = 1
531.LP
532See the \fByum.conf(5)\fR man page for more information on plugin related
533configuration options.
534
535.PP
536.SH "FILES"
537.nf
538/etc/yum/yum.conf
539/etc/yum/version-groups.conf
540/etc/yum/repos.d/
541/etc/yum/pluginconf.d/
542/var/cache/yum/
543.fi
544
545.PP
546.SH "SEE ALSO"
547.nf
548.I pkcon (1)
549.I yum.conf (5)
550.I yum-updatesd (8)
551.I package-cleanup (1)
552.I repoquery (1)
553.I yum-complete-transaction (1)
554.I yumdownloader (1)
555.I yum-utils (1)
556.I yum-security (8)
557http://yum.baseurl.org/
558http://yum.baseurl.org/wiki/Faq
559yum search yum
560.fi
561
562.PP
563.SH "AUTHORS"
564.nf
565See the Authors file included with this program.
566.fi
567
568.PP
569.SH "BUGS"
570There of course aren't any bugs, but if you find any, you should first
571consult the FAQ mentioned above and then email the mailing list:
572yum@lists.baseurl.org or filed in bugzilla.
573.fi
Note: See TracBrowser for help on using the repository browser.