Compare RPM’s on two servers

Useful if your migrating from an old server to a new one and want to check everything needed is installed.

First, pull a list of RPM package by name only:

rpm -qa –queryformat=’%{NAME}\n’ | sort > server.txt

Once you’ve done that on both servers, just use diff to compare the two files:

diff serverold.txt servernew.txt
diff serverold.txt servernew.txt > diff.txt
cat diff.txt | grep “>”

You can leave a response, or trackback from your own site.

Leave a Reply