Help Center/ Cloud Container Engine/ User Guide/ Old Console/ Clusters/ Upgrading a Cluster/ Performing In-place Upgrade (v1.15 and Later)
Updated on 2024-11-11 GMT+08:00

Performing In-place Upgrade (v1.15 and Later)

Scenario

On the CCE console, You can perform an in-place cluster upgrade to use new cluster features.

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 Overview and Before You Start.

Description

  • An in-place upgrade updates the Kubernetes components on cluster nodes, without changing their OS version.
  • Data plane nodes are upgraded in batches. By default, they are prioritized based on their CPU, memory, and PodDisruptionBudgets (PDBs). You can also set the priorities according to your service requirements.

Precautions

  • During the cluster upgrade, the system will automatically upgrade add-ons to a version compatible with the target cluster version. Do not uninstall or reinstall add-ons during the cluster upgrade.
  • Before the upgrade, ensure that all add-ons are running. If an add-on fails to be upgraded, rectify the fault and try again.
  • During the upgrade, CCE checks the add-on running status. Some add-ons (such as coredns) require at least two nodes to run normally. In this case, at least two nodes must be available for the upgrade.

For more information, see Before You Start.

Procedure

This section describes how to upgrade a CCE cluster of v1.15 or later. For other versions, see Performing Replace/Rolling Upgrade (v1.13 and Earlier).

  1. Log in to the CCE console. In the navigation pane, choose Resource Management > Clusters. In the cluster list, view the cluster version.
  2. Click More for the cluster you want to upgrade, and select Upgrade from the drop-down menu.

    Figure 1 Upgrading a cluster
    • If your cluster version is up-to-date, the Upgrade button is grayed out.
    • If the cluster status is Unavailable, the upgrade flag in the upper right corner of the cluster card view will be grayed out. Check the cluster status by referring to Before You Start.

  3. Set the upgrade parameters.

    • Available Versions: Select v1.19 in this example.
    • Cluster Backup: A manual confirmation is required for backing up the entire master node. The backup process uses the Cloud Backup and Recovery (CBR) service and takes about 20 minutes. If there are many cloud backup tasks at the current site, the backup time may be prolonged.
    • Add-on Upgrade Configuration: Add-ons that have been installed in your cluster are listed. During the cluster upgrade, the system automatically upgrades the add-ons to be compatible with the target cluster version. You can click Set to re-define the add-on parameters.

      If a red dot is displayed on the right of an add-on, the add-on is incompatible with the target cluster version. During the upgrade, the add-on will be uninstalled and then re-installed. Ensure that the add-on parameters are correctly configured.

    • Node Upgrade Configuration: Before setting the node upgrade priority, you need to select a node pool. Nodes and node pools will be upgraded according to the priorities you specify. You can set the maximum number of nodes to be upgraded in batch, or set priorities for nodes to be upgraded. If you do not set this parameter, the system will determine the nodes to upgrade in batches based on specific conditions.
      • Add Upgrade Priority: Add upgrade priorities for node pools.
      • Add Node Priority: After adding a node pool priority, you can set the upgrade sequence of nodes in the node pool. The system upgrades nodes in the sequence you specify. If you skip this setting, the system upgrades nodes based on the default policy.
    Figure 2 Configuring upgrade parameters

  4. Click Upgrade.

    Figure 3 Final step before upgrade

  5. After you click Upgrade, the cluster upgrade starts. You can view the upgrade process in the lower part of the page.

    During the upgrade, you can click Suspend on the right to suspend the cluster upgrade. To continue the upgrade, click Continue.

    Figure 4 Cluster upgrade in process

  6. When the upgrade progress reaches 100%, the cluster is upgraded. The version information will be properly displayed, and no upgrade is required.

    Figure 5 Upgrade completed

  7. After the upgrade is complete, verify the cluster Kubernetes version on the Clusters page.

    Figure 6 Verifying the upgrade success