CentOS uses packages that are included in repositories to manage the updates and upgrades of your CentOS installation / installed software. In this article, we show you how to update all packages on your CentOS 7 VPS, update specific software, and update your entire OS to a newer version.
- Connect to your VPS via SSH, or the VPS console before executing the commands below, and follow the steps as root user or use sudo
- Restart your VPS after updating the kernel. Changes are often not processed until your server is restarted.
Updating all software
With the command below, you update all software in CentOS 7:
yum -y update
-y confirms that this process may make changes to your VPS.
Updating specific software / packages
Would you rather update a specific package instead of all packages? Then you'd use the command:
yum -y update packagename
Replace 'packagename' with the name of the relevant package. In our article 'Installing software in CentOS 7', we explain how to find out the name of packages. For a total overview of all packages use:
Upgrading CentOS 7
Suppose you want to upgrade CentOS 7, for example from 7.5 to 7.6, then this works exactly the same as updating all your software packages:
yum -y update
Check the current installed version with:
cat /etc/redhat-release
Should you have any questions left regarding this article, do not hesitate to contact our support department. You can reach them via the ‘Contact Us’ button at the bottom of this page.