Bookmark this page

Guided Exercise: Upgrade Red Hat Enterprise Linux

Run an in-place upgrade of Red Hat Enterprise Linux.

Outcomes

  • Use the Leapp tool to upgrade a system from RHEL 7.9 to RHEL 8.9.

As the student user on the workstation machine, use the lab command to prepare your environment for this exercise, and to ensure that all required resources are available.

[student@workstation ~]$ lab start upgrade-upgrade

Instructions

In previous activities, you prepared a system for upgrading and performed a pre-upgrade analysis. In this activity, you test a sample application and then upgrade a system. In a future activity, you test the application again to verify the success of the upgrade.

  1. You will review a sample application before and after upgrading the serverc system to verify that the application still works after the upgrade.

    From the workstation machine, observe the sample application that is running on the serverc RHEL 7 machine. The application is a game that uses Node.js and some other operating system dependencies to function.

    Interact with the application to confirm that it works correctly.

    1. Open a browser and navigate to the http://serverc.lab.example.com site. Wait for the application to start.

    2. When the application finishes loading, press Space or click the web page to start playing.

      Press Space to prevent the bird from falling.

    3. When finished testing, close the web browser.

      After upgrading the system, you will test this application again in a future activity.

  2. Upgrade the serverc machine to RHEL 8.9.

    1. Log in to the serverc machine as the student user. Switch to the root user. Use student as the password.

      [student@workstation ~]$ ssh serverc
      student@serverc's password: student
      [student@serverc ~]$ sudo -i
      [sudo] password for student: student
      [root@serverc ~]#
    2. Verify the release version of the serverc machine.

      [root@serverc ~]# cat /etc/redhat-release
      Red Hat Enterprise Linux Server release 7.9 (Maipo)
    3. Run the Leapp tool and set RHEL 8.9 as the target for the upgrade.

      [root@serverc ~]# leapp upgrade --target 8.9
      ...output omitted...
      
      Transaction test succeeded.
      Complete!
      ====> * add_upgrade_boot_entry
              Add new boot entry for Leapp provided initramfs.
      A reboot is required to continue. Please reboot your system.
      
      
      Debug output written to /var/log/leapp/leapp-upgrade.log
      
      ============================================================
                            REPORT OVERVIEW
      ============================================================
      
      HIGH and MEDIUM severity reports:
          1. Packages available in excluded repositories will not be installed
          2. Difference in Python versions and support in RHEL 8
          3. GRUB2 core will be automatically updated during the upgrade
          4. chrony using default configuration
          5. Module pam_pkcs11 will be removed from PAM configuration
      
      Reports summary:
          Errors:                      0
          Inhibitors:                  0
          HIGH severity reports:       3
          MEDIUM severity reports:     2
          LOW severity reports:        4
          INFO severity reports:       4
      
      Before continuing consult the full report:
          A report has been generated at /var/log/leapp/leapp-report.json
          A report has been generated at /var/log/leapp/leapp-report.txt
      
      ============================================================
                         END OF REPORT OVERVIEW
      ============================================================
      
      Answerfile has been generated at /var/log/leapp/answerfile

      The leapp upgrade command finishes running, but the upgrade process is not complete. At this stage, the Leapp tool prepared the system for upgrade by assessing the system and downloading packages.

      To continue with the upgrade, the Leapp tool requires a system reboot to load a disk image that is based on RHEL 8.

    4. Reboot the serverc machine to complete the upgrade. The reboot operation triggers some other tasks such as the creation of the initial RAM file system (initramfs) and an SELinux relabel.

      [root@serverc ~]# reboot
      ...output omitted...
      [student@workstation ~]$

      After the reboot, the Leapp tool automatically continues to upgrade the system and shows the progress on the default standard output device. You can view the upgrade progress by opening the serverc machine console. On the Lab Environment tab, click Open Console on the serverc row.

      This operation might take several minutes to complete. After the machine finishes with the operation, it automatically reboots again and loads the new kernel version.

Finish

On the workstation machine, use the lab command to complete this exercise. This step is important to ensure that resources from previous exercises do not impact upcoming exercises.

[student@workstation ~]$ lab finish upgrade-upgrade

Revision: rh174-7.9-0acf85c