Compare installed rpm packages with available?

Sandra asked:

I would like to find the vmware packages that I haven’t installed from their repo.

The problem is that the output of yum search vmware is not the same format at from rpm -qa|grep vmware.


How Can I make a diff of the installed and available rpm packages?

My answer:

You need repoquery. It is in the yum-utils package.

repoquery 'vmware*'

shows all available packages named beginning with vmware.

repoquery --pkgnarrow=installed 'vmware*'

shows installed packages named beginning with vmware.

It is trivial to then compare the output of these commands.

View the full question and any other answers on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.