czerwony kapelusz

How to Upgrade from RHEL 7 to RHEL 8

How to Upgrade from RHEL 7 to RHEL 8
Long waited Red Hat Enterprise Linux 8 (RHEL 8) was released recently. One of the ways of getting RHEL 8 is to download RHEL 8 installation media (ISO image) and install it fresh on your workstation or server. But, if you already have a RHEL 7 system up and running, doing a reinstallation of the operation system may be a lot of work. Luckily, you can upgrade your existing RHEL 7 operating system to RHEL 8. Red Hat calls it an in place upgrade.

In this article, I am going to show you how to upgrade your existing RHEL 7 system to RHEL 8. So, let's get started.

Requirements:

In order to do an in place upgrade on your RHEL 7 system, you must meet the following requirements:

NOTE: Before you attempt to upgrade your operating system from RHEL 7 to RHEL 8, it's always a good idea to backup all your important data from the server. Anything can go wrong and you may end up losing your precious data. You should not take any risks.

Upgrading to RHEL 7.6:

First, make sure that the Red Hat Enterprise Linux Server subscription is attached with the following command:

$ sudo subscription-manager attach --auto

As you can see, the Red Hat Enterprise Linux Server subscription is attached.

You can list the subscription you have with the following command:

$ sudo subscription-manager list --installed

As you can see, the attached subscription in my RHEL 7 server is listed. So, I can upgrade to RHEL 7.6

Now, set the release to RHEL 7.6 with the following command:

$ sudo subscription-manager release --set 7.6

Before you start upgrading, you may check the current version of RHEL 7 you're using as follows:

$ cat /etc/redhat-release

As you can see, I am running RHEL 7.3 at the moment.

Now, to upgrade to RHEL 7.6, run the following command:

$ sudo yum update

As you can see, 275 packages (about 317 MB) will be updated. To confirm, press y and then press .

RHEL 7 will start downloading and install updates. It may take a while to complete.

All the updates should be installed.

Now, reboot your server with the following command:

$ sudo reboot

As you can see, RHEL 7 is updated to version 7.6.

Installing and Configuring leapp:

Now, you have to install leapp. leapp is used to upgrade RHEL 7.6 to RHEL 8.

First, enable the RHEL 7 Extras repository with the following command:

$ sudo subscription-manager repos --enable rhel-7-server-extras-rpms

RHEL 7 Extras repository should be enabled.

Now, install leapp with the following command:

$ sudo yum install leapp

Now, press y and then press to continue.

leapp should be installed.

Now, download the leapp data archive file with the following command:

$ wget https://access.redhat.com/sites/default/files/attachments/leapp-data3.tar.gz

NOTE: wget may not be installed on your RHEL 7 server. But, you can easily install it with sudo yum install -y wget

Now, extract the leapp data archive to the /etc/leapp/files directory with the following command:

$ sudo tar -xf leapp-data3.tar.gz -C /etc/leapp/files

Now, you may remove the leapp archive for cleanup purpose with the following command:

$ rm leapp-data3.tar.gz

Now, you can start the upgrade process.

Upgrading to RHEL 8:

Now, to upgrade to RHEL 8, run the following command:

$ sudo leapp upgrade

leapp will check whether the RHEL 7 system you have is upgradable to RHEL 8. If it is, then, it will start the upgrade process. Otherwise, it will log the problems it detected in the /var/log/leapp/leapp-report.txt file. You can check that file and fix any problem reported there. Once the problem is fixed, you can try to upgrade again.

As you can see, leapp is upgrading my RHEL 7 system to RHEL 8. It will take a while to complete.

The required packages are installed and upgraded.

Now, to finish the upgrade process, reboot your server with the following command:

$ sudo reboot

While the system is being updated, it may reboot a few times on its own.

Once the update is completed, you should see Red Hat Enterprise Linux 8.0 (Ootpa) on your login screen. As you can see, the kernel is also updated to version 4.18.

You can further verify that the upgrade was indeed successful with the following command:

$ cat /etc/redhat-release

So, that's how you upgrade from RHEL 7 to RHEL 8. Thanks for reading this article.

Gry SuperTuxKart for Linux
SuperTuxKart for Linux
SuperTuxKart is a great title designed to bring you the Mario Kart experience free of charge on your Linux system. It is pretty challenging and fun to...
Gry Battle for Wesnoth Tutorial
Battle for Wesnoth Tutorial
The Battle for Wesnoth is one of the most popular open source strategy games that you can play at this time. Not only has this game been in developmen...
Gry 0 A.D. Tutorial
0 A.D. Tutorial
Out of the many strategy games out there, 0 A.D. manages to stand out as a comprehensive title and a very deep, tactical game despite being open sourc...