AlmaLinux8
Version 1: A starting template designed for migrating away from the CentOS8 template, which has reached end-of-life. AlmaLinux serves as a one-to-one binary substitute for CentOS8.
Migration Guidance for Users Looking to Upgrade or Migrate Their CentOS8 Templates
The following is drawn from the official AlmaLinux migration guide, available at https://github.com/AlmaLinux/almalinux-deploy. For the most up-to-date details please consult that link; the instructions excerpted below were current as of March 29, 2022, and are provided solely for reference.
We provide this information as a resource for our community here in Hungary, but no liability is assumed for any errors or problems that may arise from following these notes.
almalinux-deploy
A tool for migrating from Enterprise Linux to AlmaLinux.
How to Use It
To switch your EL8 operating system over to AlmaLinux, carry out these steps:
-
Your system must be running CentOS 8.4 or 8.5 to begin the conversion to AlmaLinux. While updating to 8.5 before migration is advised, it’s not mandatory if you already have CentOS 8.4. If your system receives new packages, a reboot afterward is recommended.
sudo dnf update -y sudo reboot
- Since January 31, 2022, the CentOS 8 mirror lists have been taken offline. To run
dnf update -ysuccessfully, you must modify yourdnfconfiguration files to reference an active mirror. Thesedcommands below offer a convenient way to returndnfto a working condition so you can upgrade to 8.5 and then proceed to AlmaLinux.-
sudo sed -i -e '/mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=/ s/^#*/#/' -e '/baseurl=http://mirror.centos.org/$contentdir/$releasever// s/^#*/#/' -e '/^\[baseos\]/a baseurl=https://mirror.rackspace.com/centos-vault/8.5.2111/BaseOS/$basearch/os' /etc/yum.repos.d/CentOS-Linux-BaseOS.repo sudo sed -i -e '/mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=/ s/^#*/#/' -e '/baseurl=http://mirror.centos.org/$contentdir/$releasever// s/^#*/#/' -e '/^\[appstream\]/a baseurl=https://mirror.rackspace.com/centos-vault/8.5.2111/AppStream/$basearch/os' /etc/yum.repos.d/CentOS-Linux-AppStream.repo sudo sed -i -e '/mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=/ s/^#*/#/' -e '/baseurl=http://mirror.centos.org/$contentdir/$releasever// s/^#*/#/' -e '/^\[cr\]/a baseurl=https://mirror.rackspace.com/centos-vault/8.5.2111/ContinuousRelease/$basearch/os' /etc/yum.repos.d/CentOS-Linux-ContinuousRelease.repo sudo sed -i -e '/mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=/ s/^#*/#/' -e '/baseurl=http://mirror.centos.org/$contentdir/$releasever// s/^#*/#/' -e '/^\[devel\]/a baseurl=https://mirror.rackspace.com/centos-vault/8.5.2111/Devel/$basearch/os' /etc/yum.repos.d/CentOS-Linux-Devel.repo sudo sed -i -e '/mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=/ s/^#*/#/' -e '/baseurl=http://mirror.centos.org/$contentdir/$releasever// s/^#*/#/' -e '/^\[extras\]/a baseurl=https://mirror.rackspace.com/centos-vault/8.5.2111/extras/$basearch/os' /etc/yum.repos.d/CentOS-Linux-Extras.repo sudo sed -i -e '/mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=/ s/^#*/#/' -e '/baseurl=http://mirror.centos.org/$contentdir/$releasever// s/^#*/#/' -e '/^\[fasttrack\]/a baseurl=https://mirror.rackspace.com/centos-vault/8.5.2111/fasttrack/$basearch/os' /etc/yum.repos.d/CentOS-Linux-FastTrack.repo sudo sed -i -e '/mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=/ s/^#*/#/' -e '/baseurl=http://mirror.centos.org/$contentdir/$releasever// s/^#*/#/' -e '/^\[ha\]/a baseurl=https://mirror.rackspace.com/centos-vault/8.5.2111/HighAvailability/$basearch/os' /etc/yum.repos.d/CentOS-Linux-HighAvailability.repo sudo sed -i -e '/mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=/ s/^#*/#/' -e '/baseurl=http://mirror.centos.org/$contentdir/$releasever// s/^#*/#/' -e '/^\[plus\]/a baseurl=https://mirror.rackspace.com/centos-vault/8.5.2111/centosplus/$basearch/os' /etc/yum.repos.d/CentOS-Linux-Plus.repo sudo sed -i -e '/mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=/ s/^#*/#/' -e '/baseurl=http://mirror.centos.org/$contentdir/$releasever// s/^#*/#/' -e '/^\[powertools\]/a baseurl=https://mirror.rackspace.com/centos-vault/8.5.2111/PowerTools/$basearch/os' /etc/yum.repos.d/CentOS-Linux-PowerTools.repo
- Alternatively, you can use the
-fflag (e.g.,sudo bash almalinux-deploy.sh -f) to automate this step.
-
-
Create a system backup. Since we haven't tested every possible configuration, there's always a risk that something could go wrong. Having a backup ensures you have a restore point in that event.
-
Obtain the almalinux-deploy.sh script:
$ curl -O https://raw.githubusercontent.com/AlmaLinux/almalinux-deploy/master/almalinux-deploy.sh
-
Execute the script and review the output to ensure no errors appear:
$ sudo bash almalinux-deploy.sh ... Migration to AlmaLinux is completed
-
A reboot is recommended so that the AlmaLinux kernel is loaded:
sudo reboot -
Verify that your system has been converted successfully:
# check release file $ cat /etc/redhat-release AlmaLinux release 8.5 (Arctic Sphynx) # check that the system boots AlmaLinux kernel by default $ sudo grubby --info DEFAULT | grep AlmaLinux title="AlmaLinux (4.18.0-348.el8.x86_64) 8.5 (Arctic Sphynx)"
-
We appreciate your choice of AlmaLinux!