Search Posts on Binpipe Blog

Installing RPM's from a list

We will try to install RPM packages from a file containing a list. The following command generates a list of installed RPM packages:

rpm -qa

The same command but output the list into a file:

rpm -qa > rpms.txt

Now we can install the list of RPM packages based on the contents of the file “rpm.list”:

yum install `cat rpms.txt | sed 's/-[0-9]/*/' | cut -d"*" -f1`

The above command will use “yum” to install all packages as listed in the “rpms.txt” file.

No comments:

Post a Comment

Hi, Leave a comment here and one of the binary piper's will reply soon :)