All Products
Search
Document Center

Container Service for Kubernetes:Create a Windows node pool in an ACK cluster

最終更新日:Sep 12, 2024

Container Service for Kubernetes (ACK) allows you to create node pools and manage nodes in a cluster by node pool. For example, you can centrally manage the labels and taints of the nodes in a node pool. This topic describes how to create a Windows node pool that consists of Windows nodes in the ACK cluster.

Limits

The following table describes the limits on creating Windows node pools.

Limit

Description

Cluster

  • An ACK managed cluster is created. For more information, see Create an ACK managed cluster.

    Note
    • You can create Windows node pools only in ACK managed clusters.

    • You cannot create Windows node pools when you create an ACK cluster. You must create an ACK cluster first.

  • The cluster runs Kubernetes 1.20.4 or later.

  • The cluster uses the Flannel network.

Container runtime

Windows node pools support only the containerd runtime.

Node pool type

You can add Windows nodes only to node pools other than managed node pools.

Instance type

  • Some instance types do not support Windows node pools. When you create a Windows node pool, only the instance types that support Windows node pools can be selected. For example, you can select the ecs.g6.xlarge instance type when you create a Windows node pool.

  • Select non-GPU-accelerated instance types.

  • Select instance types that can provide more than 4 cores and 8 GB of memory.

    • If the memory usage of Windows containers exceeds the limit, the Out of Memory (OOM) Killer is not executed. Starting from May 2021, when a newly added Windows node in an ACK cluster that runs Kubernetes 1.16 or later is started, the node reserves 1.5 vCPUs, 2.5 GB of RAM, and 3 GB of disk space. The resources are reserved to ensure that the Windows operating system, kubelet, and container runtime run as normal. For more information, see Resource reservation policy.

      Note

      ACK reserves resources in case the Windows workloads overwhelm and then crash the Windows nodes. However, when a memory leak occurs in a Windows container, the Windows node that hosts the container may stop running.

    • Windows containers have a small footprint. For more information, see Memory requirements of Windows containers.

The following table describes the limits that you need to pay close attention to when you create Windows node pools.

Limit

Description

Operating system

Windows node pools support Windows Server 2019, Windows Server 2022, and Windows Server Core 2022.

Note

You can select Windows Server 2019, Windows Server 2022, and Windows Server Core 2022. If you want to use Windows Server Core 2004, you must select the latest image ID based on the release notes for ECS public images to create a node pool. For more information, see Release notes for 2023.

Number of nodes

By default, you can deploy at most 100 nodes in an ACK cluster. To add more nodes, submit an application in the Quota Center console.

ECS instance

When you add an existing Elastic Compute Service (ECS) instance to a node pool, make sure that the ECS instance is associated with an elastic IP address (EIP) or a NAT gateway is configured for the virtual private cloud (VPC) where the ECS instance is deployed. In addition, make sure that the ECS instance can access the Internet. Otherwise, you cannot add the ECS instance to the node pool. For more information, see Add existing ECS instances to an ACK cluster.

Procedure

The default node pool named default-nodepool cannot be used as the Windows node pool. Create an extra Windows node pool after you create the cluster. For more information, see Limits.

  1. Log on to the ACK console. In the left-side navigation pane, click Clusters.

  2. On the Clusters page, find the cluster that you want to manage and click its name. In the left-side navigation pane, choose Nodes > Node Pools.

  3. In the upper-right corner of the Node Pools page, click Create Node Pool, set the parameters, and then click Confirm Order.

    For more information about the parameters, see Create a node pool. The following table describes some of the parameters.

    Parameter

    Description

    Managed Node Pool

    Do not select this option.

    Container Runtime

    Select containerd.

    Instance Type

    • Some instance types do not support Windows node pools. When you create a Windows node pool, only the instance types that support Windows node pools can be selected. For example, you can select the ecs.g6.xlarge instance type when you create a Windows node pool.

    • Select instance types that can provide more than 4 cores and 8 GB of memory.

    • Select non-GPU-accelerated instance types.

      For more information about the instance types, see Instance families.

    Expected Nodes

    The number of nodes that you want the node pool to maintain. After you specify the expected number of nodes in a node pool, the nodes in the node pool are automatically scaled to the specified number.

    Operating System

    Select the Windows operating system.

    ECS Label

    Add labels to the ECS instances.

    Node Label

    Add labels to the nodes in the node pool.

    On the Node Pools page, if the Status column displays Active, the Windows node pool is created.

References

If you need to use Windows nodes and your business traffic spikes unexpectedly, we recommend that you use Windows virtual nodes and Schedule pods to run on Windows virtual nodes. For more information, see (In invitational preview) Schedule pods to run on Windows virtual nodes.