11 Useful Yum Commands on CentOS Linux

Yum is the package management system that is used on CentOS Linux. It is responsible for managing packages and their dependencies from Yum repositories, as defined in /etc/yum.repos.d/

In this post, we’ll cover a few common and useful yum commands:

1. Install a yum package:

yum install PACKAGE_NAME

2. Remove a yum package:

yum remove PACKAGE_NAME

3. Reinstall a yum package:

yum reinstall PACKAGE_NAME

4. Search for a yum package:

yum search PACKAGE_NAME

5. Display the information of a yum package:


6. Update installed yum packages:

yum update

7. Update specific yum package:

yum update PACKAGE_NAME

8. Show yum history:

yum history

9. Show a list of enabled yum repositories:

yum repolist

10. Find which yum package provides a particular file (eg: /usr/bin/nc):

yum whatprovides "*bin/nc"

11. Clear yum cache:

yum clean all
Scan to Donate Bitcoin
Like this? Donate Bitcoin to at:
Bitcoin 14M4a7UHEX61VoHkyjj4dxbUBNGGz3hmhM
Share This Post

About Author: Curtis K

Hi! My name is Curtis, and I am the creator of CentOS Blog. Please feel free to comment any suggestions, feedback or questions on my posts!