Pages

Saturday, June 24, 2017

20 Practical Examples of RPM Commands in Linux

RPM (Red Hat Package Manager) is an default open source and most popular package management utility for Red Hat based systems like (RHELCentOS and Fedora). The tool allows system administrators and users to installupdateuninstallqueryverify and manage system software packages in Unix/Linux operating systems. The RPM formerly known as .rpm file, that includes compiled software programs and libraries needed by the packages. This utility only works with packages that built on .rpm format.
RPM Command Examples
20 Most Useful RPM Command Examples
This article provides some useful 20 RPM command examples that might be helpful to you. With the help of these rpm command you can managed to install, update, remove packages in your Linux systems.

Some Facts about RPM (RedHat Package Manager)

  1. RPM is free and released under GPL (General Public License).
  2. RPM keeps the information of all the installed packages under /var/lib/rpm database.
  3. RPM is the only way to install packages under Linux systems, if you’ve installed packages using source code, then rpm won’t manage it.
  4. RPM deals with .rpm files, which contains the actual information about the packages such as: what it isfrom where it comesdependencies infoversion info etc.

There are five basic modes for RPM command

  1. Install : It is used to install any RPM package.
  2. Remove : It is used to erase, remove or un-install any RPM package.
  3. Upgrade : It is used to update the existing RPM package.
  4. Verify : It is used to query about different RPM packages.
  5. Query : It is used for the verification of any RPM package.

Where to find RPM packages

Below is the list of rpm sites, where you can find and download all RPM packages.
Please remember you must be root user when installing packages in Linux, with the root privileges you can manage rpm commands with their appropriate options.

1. How to Check an RPM Signature Package

Always check the PGP signature of packages before installing them on your Linux systems and make sure its integrity and origin is OK. Use the following command with –checksig (check signature) option to check the signature of a package called pidgin.
[root@tecmint]# rpm --checksig pidgin-2.7.9-5.el6.2.i686.rpm
pidgin-2.7.9-5.el6.2.i686.rpm: rsa sha1 (md5) pgp md5 OK

2. How to Install an RPM Package

For installing an rpm software package, use the following command with -i option. For example, to install an rpm package called pidgin-2.7.9-5.el6.2.i686.rpm.
[root@tecmint]# rpm -ivh pidgin-2.7.9-5.el6.2.i686.rpm
Preparing...                ########################################### [100%]
1:pidgin                 ########################################### [100%]
RPM command and options
  1. -i : install a package
  2. -v : verbose for a nicer display
  3. -h: print hash marks as the package archive is unpacked.
      ▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
                                                    ► Read more: http://adf.ly/1n7SsF
      ▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬

No comments:

Post a Comment