Friday, 8 March 2013

Query package owning FILE rpm

sometimes when you try to install a linux command which gives you the below. For instance lets install replace command.
# yum install replace
No package replace available.

It means that there is no such a package is available. But it belongs to software package. To know about which software is owning that command, please login to a server which has replace command installed and run this below.
# rpm -qif /usr/bin/replace
Name        : MySQL-server                 Relocations: (not relocatable)
Version     : 5.0.96                            Vendor: MySQL AB

So all we need to do is.
# yum install mysql-server

Now you should be ready to use replace command on your server.