3.4. 第 4 步:验证升级后的状态
验证升级是否成功。
本章中的说明与 章节 6 对应 - 验证 RHEL 8 系统升级后状态。
执行以下步骤:
流程
验证当前操作系统版本是否为 Red Hat Enterprise Linux 8:
cat /etc/redhat-release Red Hat Enterprise Linux release <target_os_version> (Ootpa)
# cat /etc/redhat-release Red Hat Enterprise Linux release <target_os_version> (Ootpa)
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 检查 OS 内核版本。请注意
'.el8
非常重要。例如,对于 RHEL 8.8,它将是4.18.0-477.10.1.el8
或更高版本:uname -r
# uname -r 4.18.0-477.10.1.el8
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 验证 RHEL 发行版本锁定是否已设置为在第 3 步中选择的目标操作系统版本:
在非云或 BYOS 云系统上,运行:
subscription-manager release
# subscription-manager release Release: <target_os_version>
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 在 AWS、Google Cloud 或 Azure 上的 PAYG 云实例上运行:
cat /etc/yum/vars/releasever <target_os_version>
# cat /etc/yum/vars/releasever <target_os_version>
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
验证系统是否启用了所有必要的存储库:
yum repolist
# yum repolist
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 在非云或 BYOS 云系统上,输出应包含:
rhel-8-for-x86_64-appstream-e4s-rpms rhel-8-for-x86_64-baseos-e4s-rpms rhel-8-for-x86_64-sap-netweaver-e4s-rpms rhel-8-for-x86_64-sap-solutions-e4s-rpms
rhel-8-for-x86_64-appstream-e4s-rpms rhel-8-for-x86_64-baseos-e4s-rpms rhel-8-for-x86_64-sap-netweaver-e4s-rpms rhel-8-for-x86_64-sap-solutions-e4s-rpms
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 在 AWS 上的 PAYG 云实例中,输出应包含:
rhel-8-for-x86_64-appstream-e4s-rhui-rpms rhel-8-for-x86_64-baseos-e4s-rhui-rpms rhel-8-for-x86_64-highavailability-e4s-rhui-rpms rhel-8-for-x86_64-sap-netweaver-e4s-rhui-rpms rhel-8-for-x86_64-sap-solutions-e4s-rhui-rpms
rhel-8-for-x86_64-appstream-e4s-rhui-rpms rhel-8-for-x86_64-baseos-e4s-rhui-rpms rhel-8-for-x86_64-highavailability-e4s-rhui-rpms rhel-8-for-x86_64-sap-netweaver-e4s-rhui-rpms rhel-8-for-x86_64-sap-solutions-e4s-rhui-rpms
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 在 Google Cloud 上的 PAYG 云实例上,输出应包含:
rhui-rhel-8-for-x86_64-appstream-e4s-rhui-rpms rhui-rhel-8-for-x86_64-baseos-e4s-rhui-rpms rhui-rhel-8-for-x86_64-highavailability-e4s-rhui-rpms rhui-rhel-8-for-x86_64-sap-netweaver-e4s-rhui-rpms rhui-rhel-8-for-x86_64-sap-solutions-e4s-rhui-rpms
rhui-rhel-8-for-x86_64-appstream-e4s-rhui-rpms rhui-rhel-8-for-x86_64-baseos-e4s-rhui-rpms rhui-rhel-8-for-x86_64-highavailability-e4s-rhui-rpms rhui-rhel-8-for-x86_64-sap-netweaver-e4s-rhui-rpms rhui-rhel-8-for-x86_64-sap-solutions-e4s-rhui-rpms
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 注意Google Cloud RHEL7 镜像包含 EPEL 存储库。RHEL8 镜像无法。因此,升级后,可能会出现错误消息,如下所示:
yum repolist
$ yum repolist Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/epel.repo; Configuration: OptionBinding with id "failovermethod" does not exist
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 在这种情况下,删除 EPEL 存储库:
rm -f /etc/yum.repos.d/epel*.repo
$ rm -f /etc/yum.repos.d/epel*.repo
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 在 Microsoft Azure 上的 PAYG 云实例中,输出应包含:
rhel-8-for-x86_64-appstream-e4s-rhui-rpms rhel-8-for-x86_64-baseos-e4s-rhui-rpms rhel-8-for-x86_64-highavailability-e4s-rhui-rpms rhel-8-for-x86_64-sap-netweaver-e4s-rhui-rpms rhel-8-for-x86_64-sap-solutions-e4s-rhui-rpms
rhel-8-for-x86_64-appstream-e4s-rhui-rpms rhel-8-for-x86_64-baseos-e4s-rhui-rpms rhel-8-for-x86_64-highavailability-e4s-rhui-rpms rhel-8-for-x86_64-sap-netweaver-e4s-rhui-rpms rhel-8-for-x86_64-sap-solutions-e4s-rhui-rpms
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 注意在云供应商中,存储库列表可能包含其他非红帽存储库,例如: RHUI 配置的自定义软件仓库。
-
验证网络服务是否正常运行。例如,尝试使用
ssh
连接到系统。