Migration Guide: CentOS to AlmaLinux, Rocky Linux and Other Alternatives

CentOS cover picture

CentOS 8 Reached End-of-Life on December 31, 2021

With Red Hat officially ending support for CentOS 8, users are forced to migrate to a different operating system. While CentOS 7 remains supported till end of 2024, the life cycle of the newer CentOS 8 was cut short by Red Hat for the end of 2021. Red Hat’s decision to end the CentOS 8 support remains highly controversial in the Linux community and it has stirred a lot of criticism. While the EOL of CentoOS 8 is a fact, we’re going to focus on recommending reasonable alternatives that can swiftly replace no longer supported CentOS 8.

Alternatives to CentOS 8

If your server runs CentOS, then the natural solution seems to migrate to other distribution based on Red Hat Enterprise Linux (RHEL) code. Migrating to one of the recommended RHEL derivatives will ensure a seamless experience and uninterrupted performance regardless of what you run on the server. We describe 4 RHEL derivatives in this article:

• AlmaLinux
• Rocky Linux
• Oracle Linux
• CentOS Stream

All of them aim to be 100% binary compatible with the original CentOS, meaning your current projects running on CentOS should run on each of them in the same way. From a technical perspective and from user’s experience, there is not much of a difference between the original CentOS 8 and the above-mentioned distributions.

The decision on which distribution to migrate is less about the functionality of the operating system and more about how it’s developed and maintained. Some of the alternatives are free community projects, while others are backed by large-scale commercial businesses.


First distribution we will cover is AlmaLinux, an increasingly popular semi-commercial project.

AlmaLinux is developed as a direct successor for CentOS. It is the binary equivalent to CentOS 8. But unlike Rocky Linux, the development is run by a private company. CloudLinux is a company that founded and funded the AlmaLinux OS foundation. CloudLinux invested approximately $1 million to develop AlmaLinux, after Red Hat announced discontinued support for CentOS 8. The combination of private funding and a strong community makes this distribution very promising.

This distribution is widely recognized in the IT community. For example, cPanel, developers of a popular server management panel, decided to support AlmaLinux from day one. And so did Plesk. The endorsement from both well-known panels’ developers is not only a matter of reputation, but it also guarantees easy migration for all users working with these panels.

Key features:

  • Backed by a reputable company
  • Active community
  • Works with cPanel and Plesk

Rocky Linux

When Red Hat announced the end of support for CentOS 8, one of the co-founders of the original CentOS operating system stepped in. Henry Kurtzer founded CentOS together with his colleague Rocky McGaugh in 2004. When Kurtzer decided to start working on a new substitute for CentOS, he named the new operating system after the late Rocky McGaugh. As all other alternatives mentioned in this article, the Rocky Linux distribution is based on the RHEL code, which means there are only marginal differences in code in comparison to CentOS.

Rocky Linux is an independent project with a free community support. The stable release 8.4 was released in June 2021 under the codename “Green Obsidian”. From all mentioned distributions, this is the youngest distribution, and one that is still under construction.

Since mid-2021, Henry Kurtzer has been offering paid support plans via his CIQ company, trying to offer “enterprise-grade” services . Still, the Rocky Linux distribution is at heart a community project preserving the original open-source spirit.

Key features:

  • Active community
  • Lead by CentOS founder
  • Slower release cycle
  • Young project
  • Plesk / cPanel support is missing

CentOS Stream

CentOS Stream is an alternative to CentOS 8 that comes directly from Red Hat. The main difference is that it has a different release cycle than other CentOS8 alternatives. It’s a rolling release of the RHEL, meaning that there are almost constant updates with all the newest developments in the code of the core, libraries and applications:

CentOS stream lifecycle

On one hand this means access to the newest software very quickly, on the other hand there is a higher risk of compatibility issues. It is a great idea for a development sandbox, but not necessarily for a production system.

Key features:

  • Backed by a renowned company
  • Constantly Updated

Oracle Linux

One of the less mentioned alternatives is using Linux from Oracle. Like all other alternatives, Oracle’s Linux is 100 percent binary compatible with the original Red Hat distribution. And that makes it also very close to the CentOS distribution – Oracle ensures that their Linux is fully compatible with existing CentOS 8 apps.

The biggest advantage of Oracle Linux is obvious – the support of one of the most prominent IT companies. The customer support isn’t free, but everything else is. Some users also consider as an advantage the possibility to perform updates via the yum server.

On the other hand, many users are now discouraged from using Linux distributions developed by corporations. They argue that after Red Hat discontinued support of CentOS, Oracle Linux can end up doing the same. But at least for now, the Oracle Linux remains a perfectly viable alternative, especially if you can afford their support.

Key Features:

  • Backed by a renowned company

Contabo Recommendation

All distributions mentioned above are very close to the original CentOS 8. Developers of all mentioned distributions also made it easy to migrate using just a few commands.

Your decision which alternative to use should be based on who stands behind each project. Do you trust an open community like Rocky Linux or are you more keen on projects backed by big corporations like Oracle?

If we were to recommend just one distribution, it would undoubtedly be AlmaLinux. It has the stability thanks to the backing of CloudLinux and the energy coming from the community. That’s why we recommend AlmaLinux as a safe bet for CentOS 8 users.

How to Migrate from CentOS 8

Below, you will find a brief description of the migration process for AlmaLinux, Rocky Linux, CentOS Stream and Oracle Linux.

Don’t forget to back up your data before performing the migration. If you don’t care about the data on the instance, you can simply reinstall the virtual machine without performing a migration. Contabo customers can do this in Contabo Customer Panel and choose AlmaLinux, Rocky Linux or CentOS Stream.

First, log in to your instance using SSH. Also, please make sure you have sufficient admin rights first. The easiest way how to avoid admin rights issues is to enter the command sudo -i at the beginning of each session:
sudo -i

How to migrate from CentOS 8 to AlmaLinux

Before migrating, update your current distribution by running this command:
dnf update

Download the distribution from GitHub using
curl -O https://raw.githubusercontent.com/AlmaLinux/almalinux-deploy/master/almalinux-deploy.sh

Assign all necessary permissions to the script:
chmod +x almalinux-deploy.sh

Now run the script by typing

And finally

How to migrate from CentOS 8 to Rocky Linux

Before migrating, update your current distribution by running this command:
dnf update

Rocky Linux developers have created a script called migrate2rocky. To obtain the distribution, just download it using this command:
curl -O https://raw.githubusercontent.com/rocky-linux/rocky-tools/main/migrate2rocky/migrate2rocky.sh

When the file has been finished downloading, give the script all necessary permissions by
chmod u+x migrate2rocky.sh

Now execute the script itself:
./migrate2rocky.sh -r

And finally

How to migrate from CentOS 8 to CentOS Stream

Before migrating, update your current distribution by running this command:
dnf update

Start the installation by typing:
dnf install centos-release-stream

After the installation is done, you have to change the repository for CentOS Stream:
dnf swap centos-linux-repos centos-stream-repos

And at last, let’s sync all your existing packages with the new distribution:
dnf distro-sync

and finally

How to Migrate From CentOS 8 to Oracle Linux

Before migrating, update your current distribution by running this command:
dnf update

Download the distribution from GitHub:
curl -O https://raw.githubusercontent.com/oracle/centos2ol/main/centos2ol.sh

Now run this command to replace your CentOS 8 with the Oracle:

And finally