You can upgrade the Sandboxed-Container runtime deployed on your nodes through the Container Service for Kubernetes console. This topic describes how the upgrade works, the notes that you need to pay attention to during the upgrade, and the procedure to perform the upgrade.
How it works
- Upgrade process and status transitions
When you start an upgrade, the system creates multiple upgrade tasks in the background. These tasks will be automatically distributed to nodes that need upgrades in batches and executed through pods. During the upgrade process, you can pause, resume, or cancel the upgrade based on your needs.
- After you click Upgrade, the task status becomes Upgrading.
- After you pause an Upgrading task, the task status becomes Paused.
- After you resume a Paused task, the task status becomes Upgrading again.
- After you cancel a Paused task, the task status becomes Canceled.
- Upgrade policy
Runtime upgrade is performed in batches as follows:
Assume that a cluster has 50 nodes that need upgrades. The upgrade process works as follows:
- The first batch includes one node. In subsequent batches, the number of nodes is increased by the power of 2. If you pause the upgrade and resume it later, the first batch after the pause includes one node. The number of nodes is increased by the power of 2 in batches thereafter.
- The maximum number of nodes in a batch does not exceed 10% of the total number of nodes.
- The first batch includes one node.
- The second batch includes two nodes.
- The third batch includes four nodes.
- The fourth batch includes five nodes. Even though 2 3 = 8, the cluster has only 50 nodes, which means that a maximum of five nodes can be upgraded in a batch.
- The fifth batch includes five nodes.
- The process continues until all nodes are upgraded.
- Pause the upgrade
You can pause the upgrade process at any time during the upgrade.
- After you pause the upgrade, the upgrade will be completed on nodes where the upgrade has already started. The upgrade will not be started on nodes where the upgrade has not started.
- We recommend that you do not perform operations on the cluster when the upgrade is paused and resume the upgrade as soon as possible.
- When you pause the upgrade, the system checks whether there are nodes that need upgrades left. If none is left, the pause fails and the upgrade ends.
After the upgrade is paused, you can click Continue to resume the upgrade.
If an error occurs during the upgrade, the system automatically pauses the upgrade process. The cause of the error will be displayed at the bottom of the page. You can troubleshoot the error accordingly or Submit a ticket to ask for help.
- Cancel the upgrade
After the upgrade is paused, you can click Cancel to cancel the upgrade.
- After you cancel the upgrade, the upgrade will be completed on nodes where the upgrade has already started. The upgrade will not be started on nodes where the upgrade has not started.
- Nodes that have completed the upgrade are not affected.
- To upgrade the runtime, nodes must have Internet access to download upgrade packages.
- Failures may occur during the upgrade. To ensure data security, we recommend that you take snapshots of volumes in advance.
- Applications running in the cluster will not be interrupted during the upgrade. We recommend that you check runtime release notes to decide whether you need to release applications again. For more information, see Release notes for Sandboxed-Container.
- The upgrade is performed in batches. You can pause the upgrade after a batch has been upgraded. We recommend that you resume the upgrade as soon as possible. If the upgrade has been paused for more than 15 days, it will end automatically, deleting related events and log information.
- Do not change the number of nodes in the cluster during the upgrade. To add or remove nodes, you must cancel the upgrade first.
- Do not modify the resources under the runtime-upgrade namespace during the upgrade unless an error has occurred.
- If an error occurs during the upgrade, the process will be paused. You need to troubleshoot
the error and delete the pods under the runtime-upgrade namespace. After the error has been fixed, you can resume the upgrade.
Notice Do not delete or modify resources other than pods under the runtime-upgrade namespace even if an error occurs. If you need help, contact Alibaba Cloud technical support team.
- Log on to the ACK console.
- In the left-side navigation pane, click Clusters.
- On the Clusters page, click the name of the target cluster or click Manage in the Actions column.
- On the cluster details page, choose .
- On the Runtime Upgrade page, click Upgrade.
- In the message that appears, click OK.
To pause the upgrade, click Pause. After the upgrade is paused, you can click Continue or Cancel to resume or cancel the upgrade.After you click Upgrade or Continue, you can view operation records in the events list.