将Red Hat Enterprise Linux(RHEL)7升级为RHEL 8 |
您所在的位置:网站首页 › rhel7升级内核 › 将Red Hat Enterprise Linux(RHEL)7升级为RHEL 8 |
运行以下命令,进行预升级检查。 leapp preupgrade --no-rhsm --target 8.8其中--target 8.8指定升级的目标版本为RHEL 8.8,您可以根据实际需求替换版本。如果不指定目标版本,默认升级至最新版本。 说明您可以通过leapp preupgrade -h命令查看支持升级的目标版本。 查看预升级结果。 Leapp预升级会对系统进行扫描检查,因为RHEL 7和RHEL 8的系统差异较大,需要修改部分配置以满足升级需求。Leapp工具预升级的检查日志保存在以下日志文件中: /var/log/leapp/leapp-preupgrade.log:Leapp工具的日志 /var/log/leapp/leapp-report.txt:文本格式的预升级检查报告 /var/log/leapp/leapp-report.json :JSON格式的预升级检查报告 预升级检查失败后,会打印出一些具体检查失败项, 如下图所示。 处理预升级结果。 您可以在日志文件/var/log/leapp/leapp-report.txt中查看具体的报告信息,并根据Leapp工具的建议进行修复。以下列出一些常见的预升级检查结果的处理办法。 案例1:系统中安装了多个内核版本 Risk Factor: high (inhibitor) Title: Multiple devel kernels installed Summary: DNF cannot produce a valid upgrade transaction when multiple kernel-devel packages are installed. Remediation: [hint] Remove all but one kernel-devel packages before running Leapp again. [command] yum -y remove kernel-devel-3.10.0-1160.11.1.el7处理办法:系统中安装了多个内核版本,需要卸载旧的内核包。您可以根据leapp工具的提示命令卸载旧内核,例如本案例中的yum -y remove kernel-devel-3.10.0-1160.11.1.el7。 案例2:系统中加载了RHEL 8不支持的内核模块 Risk Factor: high (inhibitor) Title: Leapp detected loaded kernel drivers which have been removed in RHEL 8. Upgrade cannot proceed. Summary: Support for the following RHEL 7 device drivers has been removed in RHEL 8: - floppy处理办法:部分模块(例如本案例的floppy模块)在RHEL 8上不支持,您可以运行以下命令进行卸载。 rmmod floppy案例3:sshd_config配置异常 Risk Factor: high (inhibitor) Title: Possible problems with remote login using root account Summary: OpenSSH configuration file does not explicitly state the option PermitRootLogin in sshd_config file, which will default in RHEL8 to "prohibit-password". Remediation: [hint] If you depend on remote root logins using passwords, consider setting up a different user for remote administration or adding "PermitRootLogin yes" to sshd_config. If this change is ok for you, add explicit "PermitRootLogin prohibit-password" to your sshd_config to ignore this inhibitor处理办法: 将配置文件/etc/sshd/sshd_config中的PermitRootLogin默认值配置为yes。 说明RHEL 7和RHEL 8的PermitRootLogin的默认值有差异: RHEL 7:默认值为yes,表示允许root使用密码、密钥登录。 RHEL 8:默认值为prohibit-password,表示禁止密码登录。 运行以下命令,重启sshd服务。 systemctl restart sshd案例4:没有编辑确认应答文件 Risk Factor: high (inhibitor) Title: Missing required answers in the answer file Summary: One or more sections in answerfile are missing user choices: remove_pam_pkcs11_module_check.confirm For more information consult https://leapp.readthedocs.io/en/latest/dialogs.html Remediation: [hint] Please register user choices with leapp answer cli command or by manually editing the answerfile. [command] leapp answer --section remove_pam_pkcs11_module_check.confirm=True处理办法:本案例需要删除RHEL 8上不支持的pam模块,需要在应答文件/var/log/leapp/answerfile中确认,您可以运行以下命令将confirm设置为True进行确认。 leapp answer --section remove_pam_pkcs11_module_check.confirm=True |
今日新闻 |
点击排行 |
|
推荐新闻 |
图片新闻 |
|
专题文章 |
CopyRight 2018-2019 实验室设备网 版权所有 win10的实时保护怎么永久关闭 |