January 3, 2013

Quickguide to the most common yum and rpm commands

The first thing you probably want to learn better after have installed a RHEL or Fedora system, is how you manage your programs. And the answer to that is the command yum or rpm. Below follows a list of the most common yum and rpm commands.

Search RPM package names.

$ yum search term

Display information about package.

$ yum info package_name

Check if package is installed.

$ yum list installed package_name

Lists all installed and available packages.

$ yum list all

List all the files in a installed package.

$ rpm -ql package_name

List all the files in a NOT installed package.

$ repoquery -q -l --plugins package_name

* Note repoquery requires packages yum-utils to be installed.

Search for package that contains certain file.

$ yum provides \*filename_to_search_after

Install package.

$ yum install package_name

Check for updates.

$ yum check-update

Run update.

$ yum update

Reference:

No comments: