Performing Replace/Rolling Upgrade

Scenario

You can upgrade your clusters to a newer Kubernetes version on the CCE console.

Before the upgrade, learn about the target version to which each CCE cluster can be upgraded in what ways, and the upgrade impacts. For details, see Upgrade Overview and Before You Start.

Precautions

Procedure

  1. Log in to the CCE console and click the cluster name to access the cluster.
  2. In the navigation pane, choose Cluster Upgrade. You can view the new version available for upgrade on the right. Click Upgrade.

    • If your cluster version is up-to-date, the Upgrade button is grayed out.
    • If your cluster status is abnormal or there are abnormal add-ons, the Upgrade button is dimmed. Perform a check by referring to Before You Start.

  3. In the displayed Pre-upgrade Check dialog box, click Check Now.
  4. The pre-upgrade check starts. While the pre-upgrade check is in progress, the cluster status will change to Pre-checking and new nodes/applications will not be able to be deployed on the cluster. However, existing nodes and applications will not be affected. It takes 3 to 5 minutes to complete the pre-upgrade check.
  5. When the status of the pre-upgrade check is Completed, click Upgrade.
  6. On the cluster upgrade page, review or configure basic information by referring to Table 1.

    Table 1 Basic information

    Parameter

    Description

    Cluster Name

    Review the name of the cluster to be upgraded.

    Current Version

    Review the version of the cluster to be upgraded.

    Target Version

    Review the target version after the upgrade.

    Node Upgrade Policy

    Replace (replace upgrade): Worker nodes will be reset. Their OSs will be reinstalled, and data on the system and data disks will be cleared. Exercise caution when performing this operation.

    NOTE:
    • The lifecycle management function of the nodes and workloads in the cluster is unavailable.
    • APIs cannot be called temporarily.
    • Running workloads will be interrupted because nodes are reset during the upgrade.
    • Data in the system and data disks on the worker nodes will be cleared. Back up important data before resetting the nodes.
    • Data disks without LVM mounted to worker nodes need to be mounted again after the upgrade, and data on the disks will not be lost during the upgrade.
    • The EVS disk quota must be greater than 0.
    • The container IP addresses change, but the communication between containers is not affected.
    • Custom labels on the worker nodes will be cleared.
    • It takes about 12 minutes to complete the cluster upgrade.

    Login Mode

    Key Pair

    Select the key pair used to log in to the node. You can select a shared key.

    A key pair is used for identity authentication when you remotely log in to a node. If no key pair is available, click Create Key Pair.

  7. Click Next. In the dialog box displayed, click OK.
  8. Upgrade add-ons. If an add-on needs to be upgraded, a red dot is displayed. Click the Upgrade button in the lower left corner of the add-on card view. After the upgrade is complete, click Upgrade in the lower right corner of the page.

    • Master nodes will be upgraded first, and then the worker nodes will be upgraded concurrently. If there are a large number of worker nodes, they will be upgraded in different batches.
    • Select a proper time window for the upgrade to reduce impacts on services.
    • Clicking OK will start the upgrade immediately, and the upgrade cannot be canceled. Do not shut down or restart nodes during the upgrade.

  9. In the displayed Upgrade dialog box, read the information and click OK. Note that the cluster cannot be rolled back after the upgrade.
  10. Back to the cluster list, you can see that the cluster status is Upgrading. Wait until the upgrade is completed.

    After the upgrade is successful, you can view the cluster status and version on the cluster list or cluster details page.