7.5. 表示集群已准备好升级

默认情况下,带有手动维护凭证的集群的 Cloud Credential Operator(CCO)U gradable 状态为 False

先决条件

  • 对于您要升级到的发行镜像,您可以手动处理任何新凭证,或使用 Cloud Credential Operator 实用程序 (ccoctl) 处理。
  • 已安装 OpenShift CLI(oc)。

流程

  1. 以具有 cluster-admin 角色的用户身份登录到集群中的 oc
  2. 运行以下命令,编辑 CloudCredential 资源,以在 metadata 字段中添加 upgradeable-to 注解:

    $ oc edit cloudcredential cluster

    要添加的文本

    ...
      metadata:
        annotations:
          cloudcredential.openshift.io/upgradeable-to: <version_number>
    ...

    其中 <version_number> 是您要升级到的版本,格式为 x.y.z。例如,OpenShift Container Platform 4.12.2 使用 4.12.2

    添加可升级状态进行更改的注解后,可能需要几分钟时间。

验证

  1. 在 Web 控制台的 Administrator 视角中,导航到 AdministrationCluster Settings
  2. 要查看 CCO 状态详情,请点击 Cluster Operators 列表中的 cloud-credential

    • 如果 Conditions 部分中的 Upgradeable 状态为 False,请验证 upgradeable-to 注解没有拼写错误。
  3. Conditions 部分中的 Upgradeable 状态为 True 时,开始 OpenShift Container Platform 升级。