Difference between revisions of "Upgrade RHEL6 to RHEL7"

From Notes_Wiki
(Created page with "Home > RHEL > Upgrade RHEL6 to RHEL7 We can upgrade from RHEL 6 to RHEL 7 as follows: # Install the tool to perform the migration from RHEL 6 to RHEL 7: #:<pre> #:: yum install redhat-upgrade-tool #:: yum install yum-utils #:</pre> # Disable all the enabled repositories: #:<pre> #:: yum-config-manager --disable \* #:</pre> # Download latest RHEL 7 ISO ## Visit the Red Hat Customer Service Portal at https://access.redhat.com/login and enter your use...")
 
m
Line 1: Line 1:
[[Main Page|Home]] > [[RHEL]] > [[Upgrade RHEL6 to RHEL7]]
[[Main Page|Home]] > [[RHEL]] > [[Upgrade RHEL6 to RHEL7]]


We can upgrade from RHEL 6 to RHEL 7 as follows:
For upgrading we need to first run pre-upgrade check.  After that we can upgrade using redhat-upgrade-tool.  Overall upgrade from RHEL 6 to RHEL 7 can be done as follows:
# Install the tool to perform the migration from RHEL 6 to RHEL 7:
# Running preupgrade check via:
## Clear the version lock
##:<pre>
##:: yum versionlock clear
##:</pre>
## Enable the Extras repository
##:<pre>
##:: subscription-manager repos --enable rhel-6-server-extras-rpms --enable rhel-6-server-optional-rpms
##:</pre>
## Install the Preupgrade Assistant and Red Hat Upgrade Tool
##:<pre>
##:: yum install preupgrade-assistant preupgrade-assistant-el6toel7 redhat-upgrade-tool
##:</pre>
## Update all packages to their latest RHEL 6 version
##:<pre>
##:: yum update
##:: shutdown -r now
##:</pre>
## Run the Preupgrade Assistant to perform an assessment of the system
##:<pre>
##:: preupg
##:</pre>
##: This should generate an HTML file for us to view.
## Resolve problems found by the Preupgrade Assistant during the assessment by following the Remediation text in the report.  ##: Sometimes for KDE and Gnome the text will include list of packages that need to be removed.  We should remove them using yum for preupg test to succeed.
## Run the Preupgrade Assistant again. If there are no new problems to be resolved, you can proceed with upgrading your system
# Upgrade
## Install the yum-utils package
##:<pre>
##:: yum install yum-utils redhat-upgrade-tool
##:</pre>
## Disable active repositories:
##:<pre>
##:: yum-config-manager --disable \*
##:</pre>
## Download latest RHEL 7 ISO
### Visit the Red Hat Customer Service Portal at https://access.redhat.com/login and enter your user name and password to log in.
### Click Downloads to visit the Software & Download Center.
### In the Red Hat Enterprise Linux area, click Download Software to download the latest version of the software.
### Copy the RHEL 7.9 iso to /root directory
## Start the upgrade
##:<pre>
##:: redhat-upgrade-tool --iso iso_path --cleanup-post
##:</pre>
##: For example
##::<pre>
##::: redhat-upgrade-tool --iso /root/rhel-server-7.9-x86_64-dvd.iso --cleanup-post
##::</pre>
## Reboot the system when prompted
##:<pre>
##:: shutdown -r now
##:</pre>
# (Optionally) Update your new RHEL 7 packages to their latest version
#:<pre>
#:<pre>
#:: yum install redhat-upgrade-tool
#:: yum update
#:: yum install yum-utils
#:</pre>
#:</pre>
# Disable all the enabled repositories:
# Verify that the system was upgraded to the desired minor version of RHEL 7
#:<pre>
#:<pre>
#:: yum-config-manager --disable \*
#:: cat /etc/*release
#:</pre>
#:</pre>
# Download latest RHEL 7 ISO
# (Optionally) Install the gnome desktop
## Visit the Red Hat Customer Service Portal at https://access.redhat.com/login and enter your user name and password to log in.
## Click Downloads to visit the Software & Download Center.
## In the Red Hat Enterprise Linux area, click Download Software to download the latest version of the software.
# Upgrade to RHEL 7 using ISO
#:<pre>
#:<pre>
#:: # redhat-upgrade-tool --iso RHEL7_ISO_filepath --cleanup-post
#:: yum groupinstall 'X Window System' 'GNOME'
#:: # reboot
#:</pre>
#(Optionally) Enable and start the graphical environment
#:<pre>
#:: systemctl set-default graphical.target
#:: systemctl start graphical.target
#:</pre>
#:</pre>



Revision as of 03:16, 12 September 2022

Home > RHEL > Upgrade RHEL6 to RHEL7

For upgrading we need to first run pre-upgrade check. After that we can upgrade using redhat-upgrade-tool. Overall upgrade from RHEL 6 to RHEL 7 can be done as follows:

  1. Running preupgrade check via:
    1. Clear the version lock
      yum versionlock clear
    2. Enable the Extras repository
      subscription-manager repos --enable rhel-6-server-extras-rpms --enable rhel-6-server-optional-rpms
    3. Install the Preupgrade Assistant and Red Hat Upgrade Tool
      yum install preupgrade-assistant preupgrade-assistant-el6toel7 redhat-upgrade-tool
    4. Update all packages to their latest RHEL 6 version
      yum update
      shutdown -r now
    5. Run the Preupgrade Assistant to perform an assessment of the system
      preupg
      This should generate an HTML file for us to view.
    6. Resolve problems found by the Preupgrade Assistant during the assessment by following the Remediation text in the report. ##: Sometimes for KDE and Gnome the text will include list of packages that need to be removed. We should remove them using yum for preupg test to succeed.
    7. Run the Preupgrade Assistant again. If there are no new problems to be resolved, you can proceed with upgrading your system
  2. Upgrade
    1. Install the yum-utils package
      yum install yum-utils redhat-upgrade-tool
    2. Disable active repositories:
      yum-config-manager --disable \*
    3. Download latest RHEL 7 ISO
      1. Visit the Red Hat Customer Service Portal at https://access.redhat.com/login and enter your user name and password to log in.
      2. Click Downloads to visit the Software & Download Center.
      3. In the Red Hat Enterprise Linux area, click Download Software to download the latest version of the software.
      4. Copy the RHEL 7.9 iso to /root directory
    4. Start the upgrade
      redhat-upgrade-tool --iso iso_path --cleanup-post
      For example
      redhat-upgrade-tool --iso /root/rhel-server-7.9-x86_64-dvd.iso --cleanup-post
    5. Reboot the system when prompted
      shutdown -r now
  3. (Optionally) Update your new RHEL 7 packages to their latest version
    yum update
  4. Verify that the system was upgraded to the desired minor version of RHEL 7
    cat /etc/*release
  5. (Optionally) Install the gnome desktop
    yum groupinstall 'X Window System' 'GNOME'
  6. (Optionally) Enable and start the graphical environment
    systemctl set-default graphical.target
    systemctl start graphical.target

Refer:


Home > RHEL > Upgrade RHEL6 to RHEL7