With CentOS Linux 8 announced dead by the end of 2021 and CentOS Stream being an entirely different release and support model, one wonders if it’s possible to switch to Oracle Linux.
What’s Oracle Linux? Like CentOS, it’s a Red Hat Enterprise Linux rebuild, with some Oracle patches on top. One of the key differences is choosing either RHEL-compatible kernel or their own Unbreakable Linux kernel. To know more about Oracle Linux, read this PDF or head over to their homepage.
Oracle has 6.10, 7.9 and 8.3 versions ready to download. Since many infrastructure providers such as Digital Ocean do not have Oracle Linux on offer and given the OL similarity to CentOS, one can try to switch directly from the CentOS system.
The switch itself requires the removal of certain packages, changing the YUM/DNF repositories, and installation of a few new packages.
For version 6 and 7, Oracle prepared a migration script:
$ curl -O https://linux.oracle.com/switch/centos2ol.sh
$ sh centos2ol.sh
What does this script do?
It switches your repositories to base https://yum.oracle.com
URL.
It removes the following packages:
- centos-release-cr
- libreport-plugin-rhtsupport
- yum-rhn-plugin
- desktop-backgrounds-basic
- centos-logos
- libreport-centos
- libreport-plugin-mantisbt
- sl-logos
Depending on the version, it installs these new packages:
- basesystem
- initscripts
- oracle-logos
- plymouth (CentOS 7)
- grub2 (CentOS 7)
- oraclelinux-release-notes (CentOS 6)
- plymouth (CentOS 6)
- grub (CentOS 6)
- grubby
- kernel-uek
Hopefully, Oracle will do an update for CentOS 8 soon as well. Also, note that you can use this script for RHEL versions as well.