Sejak Januari 2022, dukungan untuk CentOS 8 telah berakhir. Namun Anda masih dapat mengonversi sistem CentOS 8 ke CentOS Stream, Rocky Linux, atau Almalinux tanpa perlu melakukan instalasi ulang dari awal menggunakan file ISO.
Cek versi CentOS 8 menggunakan perintah berikut.
[centos@ ~]$ cat /etc/redhat-release
CentOS Linux release 8.2.2004 (Core)
Update CentOS 8
Sebelum install Almalinux, pastikan Anda sudah melakukan upgrade versi CentOS 8 Anda ke versi latest atau 8.5.2111
Caranya edit file repo CentOS-AppStream.repo dan CentOS-Base.repo menjadi seperti berikut
# CentOS-AppStream.repo
#
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror to pick mirrors that are updated to and
# geographically close to the client. You should use this for CentOS updates
# unless you are manually picking other mirrors.
#
# If the mirrorlist= does not work for you, as a fall back you can try the
# remarked out baseurl= line instead.
#
#
[AppStream]
name=CentOS-$releasever - AppStream
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=AppStream&infra=$infra
#baseurl=http://mirror.centos.org/$contentdir/$releasever/AppStream/$basearch/os/
baseurl=http://vault.centos.org/$contentdir/$releasever/AppStream/$basearch/os/
gpgcheck=1
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
# CentOS-Base.repo
#
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror to pick mirrors that are updated to and
# geographically close to the client. You should use this for CentOS updates
# unless you are manually picking other mirrors.
#
# If the mirrorlist= does not work for you, as a fall back you can try the
# remarked out baseurl= line instead.
#
#
[BaseOS]
name=CentOS-$releasever - Base
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=BaseOS&infra=$infra
#baseurl=http://mirror.centos.org/$contentdir/$releasever/BaseOS/$basearch/os/
baseurl=http://vault.centos.org/$contentdir/$releasever/BaseOS/$basearch/os/
gpgcheck=1
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
Lalu update CentOS 8 dengan yum update
yum -y update
Setelah proses update selesai, reboot server dan cek versi CentOS kembali
[root@ ~]# cat /etc/redhat-release
CentOS Linux release 8.5.2111
Migrasi ke Almalinux
Download Migration Script Almalinux
curl -O https://raw.githubusercontent.com/AlmaLinux/almalinux-deploy/master/almalinux-deploy.sh
Jalankan script
bash ./almalinux-deploy.sh
Tunggu proses deploy selesai lalu reboot server kembali.
Cek versi OS
[root@ ~]# cat /etc/almalinux-release
AlmaLinux release 8.5 (Arctic Sphynx)