By now you know about the disaster that was CentOS. If not, let me sum it up: Red Hat made the shortsighted move to rid the world of the CentOS we know and love. In its place comes the pseudo-rolling release CentOS Stream that few CentOS admins trust to use and many third-party applications (such as cPanel) won’t support.

That’s about the gist of it.

This change resulted in (at least) a couple of exciting CentOS forks. The first announced was Rocky Linux, from the man who originally brought us CentOS. Next in line came AlmaLinux. Both are 1:1 binary replacements for the current Red Hat Enterprise Linux server OS and are already making strides in becoming the de facto replacement for CentOS.

The good news is that the first AlmaLinux stable release will arrive March 30, 2021, so mark your calendars. You can already test the beta of AlmaLinux which picks up exactly where CentOS 8 left off. For those of you who already have plenty of CentOS deployments in your data center, what do you do?

Fortunately, the developers of AlmaLinux have created an easy method of migrating those CentOS 8 servers to AlmaLinux, and I’m going to show you how.

It’s quite simple, so prepare to start and finish this in no time, unless you have to upgrade CentOS first, which can take a while.

SEE: Kubernetes security guide (free PDF) (TechRepublic)

What you’ll need

  • A running instance of CentOS 8
  • A user with sudo privileges

I’ve tested this process on a number of CentOS servers, and it succeeds without failure, every time.

How to migrate CentOS to AlmaLinux

Log in to your CentOS 8 server and make sure to first upgrade CentOS with the command:

sudo dnf upgrade -y

The migration to AlmaLinux will fail if CentOS is out of date.

When the upgrade completes, reboot if necessary and then download the migration script with the command:

curl -O

Once the script is saved to your local drive, give it the proper permission with the command:

chmod u+x

You can now start the migration with the command:

sudo ./

Depending on the state of CentOS when you start, the migration might actually take less time than the upgrade. Once the migration completes, reboot a second time and you’re done. You’ve successfully migrated CentOS to the 1:1 binary replacement for Red Hat Enterprise Linux. Congratulations, you don’t have to worry about drowning in the CentOS Stream.

Subscribe to TechRepublic’s How To Make Tech Work on YouTube for all the latest tech advice for business pros from Jack Wallen.

Image: AlmaLinux