Sajid Ali
Sajid Ali
Linux & Windows Server Administrator | Cloud Architect: I possess 10 years of professional experience with administration of different hosting provider’s Linux and Windows based servers on a large production level.

How to migrate from CentOS 8 to Rocky Linux.

Rocky Linux is a Linux distribution that is intended to be a downstream, complete binary-compatible release using the Red Hat Enterprise Linux operating system source code. The project’s aim is to provide a community-supported, production-grade enterprise operating system.


Backup project and important files/directories:

Take a full backup of your important config files, directories, project files and databases etc. So, if something goes wrong, we should be able to go back quickly.

Step # 1:  Installing all updates on CentOS 8.

First, make sure all the existing packages on your system are up to date.

dnf update

Now, verify CentOS Linux 8 version.




Step # 2: Installing git client on CentOS 8.

We need git to install the migration script.

First, check if git is already installed on the server? Execute the command below.

type -a git

Let us search for the git package, Execute below command.

dnf list git

dnf search git

dnf info git

Now, install git on your server with the help of the dnf utility, Execute the command below.

dnf install git

type -a git

Clone the repo to install migration tool called rocky-tool

Finally, we need to clone the rocky-tools repo with the help of the git command:

cd /tmp/

git clone

Step # 3: Migrating from CentOS 8 to Rocky Linux.

Change the directory using cd command where rocky-tools cloned:

cd /tmp/rocky-tools/migrate2rocky

Set up executable permissions using the chmod command:

chmod -v +x

Start the migration from CentOS 8 to Rocky Linux by typing the command:

./ -r

Step # 4: Reboot the system.

Now, reboot server using following command:

systemctl reboot

Step # 5: Verification the Server version.

Check the server version using command below.

cat /etc/redhat-release


cat /etc/rocky-release

Make sure there are no errors, execute the command below.

tail -f /var/log/messages


In this article you have learned how to migrate from CentOS 8 to Rocky Linux. Check out the Rocky Linux website for documentation and GitHub link.


Please enter your comment!
Please enter your name here

Latest articles

Join us on Facebook