INTRODUCTION

it's a great idea to update your server on a regular time for security and stability. use this manual to hold your centos server up to date.

SUPPORTED VERSION
This guide applies to the below version, each with and without SELinux enabled.

Centos 8
Centos 7
Centos 6


Make a backup
Always make a backup earlier before updating your system.

1. Update the Package Database

Use yum check-update to update the package database from the enabled repositories.

$ sudo yum check-update

 

2. Upgrade Packages

Use yum update to upgrade the packages.

$ sudo yum update

 

3. Restart the Server

$ sudo reboot

 

One Line Upgrade

If you want to accept all the defaults and perform the upgrade without intervention:

$ sudo yum check-update && sudo yum update -y

 

Conclusion

Regular updates keep your server secure and stable. Make sure you have a snapshot or backup strategy in place before updating.

 

Was this answer helpful? 21 Users Found This Useful (0 Votes)