All Products
Search
Document Center

Container Service for Kubernetes:Node pool overview

Last Updated:Aug 06, 2024

You can use node pools to facilitate node management. For example, you can schedule, configure, or maintain nodes by node pool, and enable auto scaling for a node pool. This topic describes node pools and compares regular node pools with managed node pools. This topic also describes the features, billing, terms, and lifecycle of node pools.

Overview

Container Service for Kubernetes (ACK) introduces node pools to improve the efficiency of node management. A node pool is a collection of nodes in an ACK cluster. You can create one or more node pools of different types and configurations for each ACK cluster. The configurations of a node pool consist of node attributes, such as the node type, zone, labels, and taints. You can configure these attributes when you create the node pool or modify the attributes after the node pool is created. For more information about how to create a node pool, see Create a node pool. For more information about how to modify a node pool, see Modify a node pool.

After you create node pools, you can deploy and manage different types of nodes in the cluster.

  • You can create node pools on different OS images, such as ContainerOS, Alibaba Cloud Linux, and Windows, in a cluster.

  • You can create node pools that use different container runtimes, such as containerd, Docker, and Sandboxed-Container, in a cluster.

  • You can create node pools that use different billing methods, such as pay-as-you-go, subscription, and pay-by-preemptible-instance, in a cluster.

  • You can create multiple node pools for which the auto scaling feature is enabled in a cluster.

image

Regular node pools and managed node pools

Node pool types

ACK provides regular node pools and managed node pools.

Node pool type

Description

Regular node pool

A regular node pool contains one or more nodes that have the same configurations in a cluster. Each node pool corresponds to a scaling group. When you scale a regular node pool, ACK uses Auto Scaling to add or remove nodes. You can create and manage multiple regular node pools based on your requirements.

Note

Some system components are installed in the default node pool. When the system automatically scales the default node pool, the system components may become unstable. If you want to use the auto scaling feature, we recommend that you create a new node pool for which the auto scaling feature is enabled.

Managed node pool

Managed node pools can automate O&M tasks for specific nodes. For example, managed node pools can automatically patch Common Vulnerabilities and Exposures (CVE) vulnerabilities or fix specific issues. This reduces your O&M work.

For more information, see Overview of managed node pools.

Comparison of features

Feature

Regular node pool

Managed node pool

O&M

Managed by users.

Partially managed by ACK.

O&M time window

No O&M time window needs to be set.

An O&M time window must be set. Managed node pools automatically perform O&M operations, such as CVE vulnerability patching, during the specified O&M time window.

Node repair

Manually performed.

Automatically performed.

Note

Managed node pools help simplify your O&M work. However, you may still need to manually fix some complicated node anomalies. For more information about automatic node repair, see Auto repair.

CVE vulnerability patching

Manually triggered by users.

Automatically triggered.

Note

CVE vulnerability patching is an advanced feature provided by Security Center. To use the CVE vulnerability patching feature, you must purchase Security Center Enterprise Edition or higher. ACK does not charge additional fees. For more information, see Functions and features.

Component update

Manually performed.

Automatically performed.

Minor kubelet version update

Manually performed.

Automatically performed.

Fast ContainerOS node scale-out

Not supported.

Supported.

ContainerOS nodes can be quickly scaled out. Compared with scaling out 1,000 CentOS nodes, which requires 330 seconds for 90% of the nodes to be ready, it requires only 53 seconds if you use ContainerOS nodes.

Note

ContainerOS is an operating system that Alibaba Cloud provides for containerized development. ContainerOS is fully compatible with Kubernetes. For more information, see ContainerOS overview.

Operating systems

Operating systems such as ContainerOS, Alibaba Cloud Linux, Red Hat, Ubuntu, and Windows are supported.

Operating systems such as ContainerOS, Alibaba Cloud Linux, Red Hat, and Ubuntu are supported.

For more information about the OS images supported by ACK and the limits on OS images, see Overview of OS images.

Note
  • You must remove all nodes in a node pool before you can delete the node pool.

  • You can enable the auto scaling feature for a node pool only when you create the node pool. After the auto scaling feature is enabled for a node pool, the node pool has the following characteristics:

    • Manual scale-out is not supported.

    • The pay-by-preemptible-instance billing method is supported.

    • Standard CPU instances, GPU-accelerated instances, and shared GPU-accelerated instances are supported in scaling activities.

    • You can disable the auto scaling feature to convert an elastic node pool into a regular node pool. However, you cannot convert a regular node pool to an elastic node pool.

    For more information, see Enable node auto scaling.

Features of node pools

The following table describes the features supported by node pools.

Feature

Description

Create a node pool

Create a node pool. You need to specify the configurations of the node pool.

Modify a node pool

Modify the configurations of a node pool.

Important

In most cases, after you modify a node pool, the modified configurations apply only to newly added nodes. The modified configurations also apply to the existing nodes in the cluster only in cases such as synchronizing the existing node labels and taints. If you perform O&M operations on a node pool, such as node pool upgrades, node repairing, vulnerability patching, and kubelet configuration customization, the system modifies the configurations of the existing nodes in the node pool.

Scale a node pool

Modify the desired number of nodes in a node pool.

  • If you increase the value, nodes are added to the node pool.

  • If you decrease the value, nodes in the node pool are released in descending order of creation time.

Add existing ECS instances to an ACK cluster

Add existing nodes that do not belong to any clusters to a node pool. However, this feature has limits. For more information about the limits on adding existing nodes, see the Limits section of the "Add existing ECS instances to an ACK cluster" topic.

Remove a node

Remove one or more specified nodes from a node pool. The removed nodes no longer belong to the cluster or node pool. You can specify whether to drain a node and release the instance before you remove a node.

Update a node pool

Update the operating system image, runtime, and kubelet for all nodes in a node pool. To reduce the negative impact on cluster workloads, we recommend that you update the nodes in batches. After the node pool is updated, nodes that are newly added to the node pool all use the updated configurations.

Note

Managed node pools can be automatically updated within the O&M time window.

Repair nodes in a node pool

Repair abnormal nodes in a node pool. Nodes are repaired one after one.

Note

Managed node pools can automatically repair abnormal nodes.

Patch OS CVE vulnerabilities for node pools

Patch vulnerabilities in the nodes of a node pool. To reduce the negative impact on cluster workloads, we recommend that you patch the nodes in batches.

Note

Managed node pools can automatically patch vulnerabilities within the O&M time window.

Customize the kubelet configurations of a node pool

Modify the kubelet configurations of the nodes in a node pool. The modified kubelet configurations also apply to nodes that are newly added to the node pool.

Enable node auto scaling

Auto Scaling can add regular instances, GPU-accelerated instances, and preemptible instances to node pools based on the actual loads and scaling policy. You can specify multiple zones, instance types, and scaling modes to meet the requirements of different scenarios and reduce the cost.

Billing of node pools

You can use node pools free of charge. However, you are charged for the cloud resources, such as ECS instances, used in node pools.

Note

If you want to change the billing method of the existing nodes in a node pool, log on to the ECS console. For more information, see Change the billing method of an instance from pay-as-you-go to subscription.

Terms related to node pools

Term

Description

scaling group

Node pools use scaling groups to manage nodes. A scaling group is a collection of ECS instances. These instances are considered logical resources used for auto scaling and management purpose. Node pools manage nodes based on scaling groups. The resources in a node pool, including ECS instances and scaling groups, must belong to the same Alibaba Cloud account. For more information, see Overview.

Important

You must use node pools to configure and manage nodes. Do not use scaling groups to configure or manage nodes. Otherwise, some node pool features may become unavailable.

scaling configuration

Node pools use the scaling configuration to manage the configurations of nodes. The scaling configuration is used by ECS instances as a scaling template when the auto scaling feature is enabled. When Auto Scaling triggers a scale-out activity, Auto Scaling creates ECS instances based on the scaling configuration.

Important

Do not use the Auto Scaling console or call the Auto Scaling API to modify the scaling configuration if some node pool features become unavailable. We recommend that you configure and manage nodes by using node pools.

scaling activity

Scaling activities are triggered when a node pool is scaled in or out. After a scaling activity is triggered, the system automatically completes the scaling operation and generates a record. You can view the historical scaling activities of a node pool in the console.

replace system disks

When the system performs node pool-related operations, it initializes the nodes in the node pool by replacing the system disk of the nodes. For example, the system replaces the system disk of the nodes when it automatically adds existing nodes to a node pool or updates the image used by the nodes. The Infrastructure as a Service (IaaS) attributes of the nodes, such as the node name, instance ID, and IP address, remain unchanged after the nodes are initialized. However, the data in the system disk of the nodes are deleted in order to initialize the nodes. The data disks that are mounted to the nodes are not affected.

Important

We recommend that you use data disks instead of system disks for persistent data storage.

in-place upgrade

You can upgrade the components on a node based on your business requirements. This is an alternative to replacing the system disk of a node. In-place upgrades do not replace system disks, initialize nodes, or destroy the data on nodes.

References

  • For more information about parameters to configure a node pool during creation, see Create a node pool.

  • You can scale out a node pool to add one or more Elastic Compute Service (ECS) nodes with the same configuration. For more information, see Scale a node pool.

  • You can add existing nodes to a node pool. For more information, see Add existing ECS nodes to an ACK cluster.

  • For more information about the detailed operations and precautions when you remove nodes from a node pool, see Remove a node.

  • For more information about O&M tasks for node pools, such as upgrading the node pool, auto repair, and patching OS CVE vulnerabilities for node pools, see Node pool O&M.

  • For more information about best practices for node pools, such as using a deployment set to distribute your ECS instances to different physical servers to ensure high availability and preemptible instance-based node pools, see Best practices for nodes and node pools.

  • Clusters that run Kubernetes 1.24 or later no longer use Docker as the built-in container runtime. We recommend that you migrate to containerd. For more information, see Migrate the container runtime from Docker to containerd.

  • For more information about how to troubleshoot if an issue occurs when you use nodes or node pools, see FAQ about nodes and node pools.

  • For more information about how to specify node pools for a specific application, see Schedule application pods to a specific node pool.