How to migrate CentOS to Rocky Linux


As you may already notice, RedHat decided to abandon the CentOS 8 project, which will reach EOF on December 31, 2021, and shift its focus to CentOS Stream. This tutorial is going to show you how to migrate from CentOS to Rocky Linux or Alma Linux.

Which Alternatives you can use ?

You can choose one of the options below:

  • Red Hat Enterprise Linux Server (Price starting from US$349)
  • Rocky Linux: A project led by one of the original creators of CentOS.
  • Alma Linux: Created by CloudLinux, which is a Linux hosting software company.

Back up of the system. We didn’t test all possible scenarios so there is a risk that something goes wrong. In such a situation you will have a restore point.

Before migration
  1. First things first! update your current OS, with
sudo dnf update -y
sudo reboot

  1. Download the update script
curl -O
  1. Run the update scrip
# Add execution permission to this script.
chmod +x
# Run the script as root
sudo ./ -r

It will replace the CentOS repository with Rocky Linux repository and also replace the software packages. The script will take care of everything. You don’t need to intervene in this process.

  1. Reboot is recommended to boot with Rocky Linux kernel:
sudo reboot
  1. Ensure that your system was successfully converted
cat /etc/rocky-release

Click to rate this post!
[Total: 2 Average: 5]


Please enter your comment!
Please enter your name here