How to Check Whether a Package is Installed in Linux
Today I come with a short and simple command that will be useful for Linux newbies. What to do if you need to find out whether the package you need is already installed or not? There is a short command that will allow you to do this.
rpm -qa | grep <package>
What does this do? This command queries all installed rpms and sends them to grep that is able to tell us whether it is the package we need. For example, if we need to know whether httpd is installed (I mean rpm installations only, compiling apache from source has nothing to do with rpm), we need to enter this command:
rpm -qa | grep httpd
I think this command will be useful for you: you will always know what software you have installed on your server. If you need to list all the packages that are installed, you’re welcome to type:
rpm -qa
This command will list all the packages you have.
Categories: Linux Tricks check installed package linux, check package installed, check what's installed on linux, check whether the rpm is installed or not, checking installed linux packages, checking installed packages on linux, how to check for packages in linux, how to check package is installed or not, how to check what is installed in linux, how to check whats installed on linux, how to check whether an rpm is installed, is httpd installed, linux check what's installed, linux checking for installed packages, linux how to check package, rpm list installed packages