해당 문서는 RHEL7.9 에서 RHEL8 로 업그레이드 하는 방법을 나열한 문서입니다.
내부망 만을 이용하여 업그레이드 하였으며, 레포는 로컬 레포를 이용하여 업그레이드 작업 수행
## repository file - rhel-7 rhel-7-server-rpms rhel-7-server-extras-rpms ## repository file - rhel-8 rhel-8-for-x86_64-baseos-rpms rhel-8-for-x86_64-appstream-rpms
# yum update -y # sync;sync;sync; # reboot
# yum install leapp leapp-repository
## https://access.redhat.com/articles/3664871 사이트 참고하여 데이터 다운로드 # wget https://access.redhat.com/node/3664871/5121/0/20659902 # tar -xzf leapp-data14.tar.gz -C /etc/leapp/files # ls -al /etc/leapp/files/ -rw-rw-r--. 1 1000 1000 3057300 May 14 23:00 pes-events.json -rw-rw-r--. 1 1000 1000 39703 Apr 27 16:19 repomap.csv -rw-rw-r--. 1 1000 1000 20711 Jan 26 2021 unsupported_driver_names.json -rw-rw-r--. 1 1000 1000 47708 Jan 26 2021 unsupported_pci_ids.json
# cat /etc/locale.conf LANG="en_US.UTF-8"
NIC interface 가 ethX 명명되어 있으면, 일관된 네트워크 장치 이름으로 변경하여야 한다.
### 기존 rhel79 repo는 비활성화 # rhel-8-for-x86_64-baseos-rpms # rhel-8-for-x86_64-appstream-rpms
## RHEL8에서 사용되지 않는 드라이버 삭제 # lsmod | grep -q floppy && sudo rmmod floppy # lsmod | grep -q pata_acpi && sudo rmmod pata_acpi # leapp preupgrade --no-rhsm --enablerepo rhel-8-for-x86_64-baseos-rpms --enablerepo rhel-8-for-x86_64-appstream-rpms ============================================================ UPGRADE INHIBITED ============================================================ Upgrade has been inhibited due to the following problems: 1. Inhibitor: Missing required answers in the answer file Consult the pre-upgrade report for details and possible remediation. ============================================================ UPGRADE INHIBITED ============================================================ Debug output written to /var/log/leapp/leapp-preupgrade.log ============================================================ 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 ============================================================ Answerfile has been generated at /var/log/leapp/answerfile ## Answerfile 열어서 안에 있는 내용에 대해 응답 해야함 # leapp answer --section remove_pam_pkcs11_module_check.confirm=True ## preupgrade 재수행 # leapp preupgrade --no-rhsm --enablerepo rhel-8-for-x86_64-baseos-rpms --enablerepo rhel-8-for-x86_64-appstream-rpms Debug output written to /var/log/leapp/leapp-preupgrade.log ============================================================ 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 ============================================================ Answerfile has been generated at /var/log/leapp/answerfile ## 위와 같이 나오면 성공
# leapp upgrade --no-rhsm --enablerepo rhel-8-for-x86_64-appstream-rpms --enablerepo rhel-8-for-x86_64-baseos-rpms # sudo touch /.autorelabel # reboot
# cat /etc/redhat-release Red Hat Enterprise Linux release 8.4 (Ootpa) # uname -r 4.18.0-305.el8.x86_64
### RHEL7 패키지 확인 # rpm -qa | grep -e '\.el[67]' | grep -vE '^(gpg-pubkey|libmodulemd|katello-ca-consumer)' | sort kernel-3.10.0-1160.36.2.el7.x86_64 kernel-3.10.0-1160.el7.x86_64 leapp-0.12.0-1.el7_9.noarch leapp-repository-0.13.0-2.el7_9.noarch python2-leapp-0.12.0-1.el7_9.noarch python-passlib-1.6.5-2.el7.noarch sshpass-1.06-2.el7.x86_64 ustr-1.0.4-16.el7.x86_64 ## RHEL7 커널 확인 및 모듈 삭제 # cd /lib/modules && ls -d *.el7* 3.10.0-1160.36.2.el7.x86_64 3.10.0-1160.el7.x86_64 # [ -x /usr/sbin/weak-modules ] && /usr/sbin/weak-modules --remove-kernel 3.10.0-1160.36.2.el7.x86_64 # [ -x /usr/sbin/weak-modules ] && /usr/sbin/weak-modules --remove-kernel 3.10.0-1160.el7.x86_64 ## 부트로더에서 커널 제거 # /bin/kernel-install remove 3.10.0-1160.36.2.el7.x86_64 /lib/modules/3.10.0-1160.36.2.el7.x86_64/vmlinuz