fbpx
Home » Blog » How to Migrate from CentOS 8 to AlmaLinux 8: A Step-by-Step Guide

How to Migrate from CentOS 8 to AlmaLinux 8: A Step-by-Step Guide

How to Migrate from CentOS 8 to AlmaLinux 8: A Step-by-Step Guide

CentOS 8 has been the go-to operating system for many system administrators for years. However, with the emergence of new distributions like AlmaLinux, it may be time to consider making a change. In this guide, we will show you how to migrate from CentOS 8 to AlmaLinux 8, preserving all of your configurations, applications, and data.

Prerequisites

Before we begin the migration process, there are a few things that you need to have in order to proceed. First and foremost, you need to have a working CentOS 8 operating system. Additionally, the script that we will be using to migrate to AlmaLinux supports the following operating systems and control panels:

  • CentOS 8
  • Oracle Linux 8
  • RHEL 8
  • Rocky Linux 8
  • Control panels such as DirectAdmin, cPanel, and Plesk

Step 1: Log in as the root User

In order to perform the migration, you need to log in as the root user. You can do this by running the following command in the terminal:

sudo -i

Step 2: Apply Pending Updates

It is important to apply any pending updates to your CentOS 8 operating system before starting the migration process. You can do this by running the following command:

dnf update

Step 3: Reboot the System

Once you have applied the updates, you should reboot the system to make sure that any new kernel updates are installed. To do this, run the following command:

Step 4: Download the almalinux-deploy.sh Script

The next step is to download the almalinux-deploy.sh script. You can do this by using the wget or curl command:

reboot

Step 5: Set up Executable Permission

After downloading the script, you need to set up the executable permission. You can do this by running the following command:

wget https://raw.githubusercontent.com/AlmaLinux/almalinux-deploy/master/almalinux-deploy.sh

Step 6: Migrate from CentOS 8 to AlmaLinux 8

Now that you have set up the executable permission, you can proceed to migrate from CentOS 8 to AlmaLinux 8 by running the following command:

chmod -v +x almalinux-deploy.sh

Note: As of January 31, 2022, the official CentOS 8 mirrorlists are offline. In order to successfully perform the dnf update -y command, you need to update your dnf config files to point to a valid mirror. If you encounter any errors, you can run the following command instead:

Step 7: Verify the AlmaLinux Version

Once the migration process is complete, it is important to verify that AlmaLinux has been installed successfully. You can do this by running the following commands:

./almalinux-deploy.sh

or

./almalinux-deploy.sh -f

Step 8: Verify Running Services

Finally, it is important to verify that all services such as PostgreSQL, Apache, and others are running correctly. You can do this by using the ps or systemctl command:

systemctl status [service_name]

Replace [service_name] with the name of the service you want to check, for example:

systemctl status apache2

And that’s it! You have successfully migrated from CentOS 8 to AlmaLinux 8. It’s recommended to check the system logs for any errors or warnings, and to perform a backup of all your important data before starting the migration process. Additionally, it’s always a good idea to test your applications and configurations to make sure they are working as expected.

In conclusion, migrating from CentOS 8 to AlmaLinux 8 is a straightforward process that can be done in just a few steps. By following this guide, you will be able to preserve all of your configurations, applications, and data, making the transition as seamless as possible.

Scroll to Top