Container Service for Kubernetes supports creating nodes with the Aliyun Linux 2 operating system and provides optimizations for multiple scenarios based on the high performance kernel of Aliyun Linux 2. This topic describes the benefits of using Aliyun Linux 2 in Container Service for Kubernetes and the optimizations that are provided in different scenarios.
Aliyun Linux 2 is a next-generation operating system developed by Alibaba Cloud. It provides a safe, stable, and high-performance running environment for applications on ECS instances. As a Linux distribution deeply optimized for cloud infrastructure, Aliyun Linux 2 offers various customizable options to achieve unparalleled runtime experience. You can use the Aliyun Linux 2 public image to create instances for free, and enjoy long-term technical support for the operating system from Alibaba Cloud.
- The Linux distribution with the fastest boot time on Alibaba Cloud.
- Deeply optimized for large-scale VMs and bare metal servers. Especially suitable for multi-task scenarios that involve large-scale instances.
- Pre-installed with commonly used software such as Alibaba Cloud CLI and cloud-init, which lowers the costs of cloud resource management.
- A streamlined kernel that minimizes the attack surface and system resource occupation.
- A well-rounded technical support system that offers multiple channels on Alibaba Cloud.
- Provides vulnerability fixes at the earliest opportunity.
- Supports live patching of the kernel, which ensures service continuity when vulnerability fixes are applied.
- Drastically speeds up system boot time of ECS instances. Quickly scales up computing resources when system overload is detected. Reduces system boot time by 29% compared with CentOS 7.
- Provides optimizations for ECS instances in multi-task scenarios and improves the performance of large-scale instances by 16%.
- Improves the efficiency of system scheduling by 11%.
- Optimizes the Linux networking stack to offer 7.8% higher network performance compared with CentOS 7.
- By default, Aliyun Linux 2 has compiled the Bottleneck Bandwidth and Round-trip Propagation Time (BBR) congestion control algorithm. In scenarios that involve frequent Internet access, you can change the congestion control algorithm of containers to BBR to improve the bandwidth stability of Internet access.
- Optimizes the TLS encryption protocol.
- Supports the Budget Fair Queueing (BFQ) I/O scheduler to reduce disk latency.
- Container network optimization
Aliyun Linux 2 is equipped with kernel 4.19. The Terway network plug-in supports the IPVLAN driver, which offers 40% higher network performance in short-packet communications compared with the traditional bridge interface and policy-based routing (PBR). By default, Aliyun Linux 2 has compiled the Bottleneck Bandwidth and Round-trip Propagation Time (BBR) congestion control algorithm. In scenarios that involve frequent Internet access, you can change the congestion control algorithm of containers to BBR to improve the bandwidth stability of Internet access. This drastically enhances public network performance and speeds up image pull across different public networks.
- Sandboxed container support
Alibaba Cloud has established partnerships with the Kata Containers and Clear Linux communities. You can seamlessly deploy the Kata Containers solution on ECS bare metal instances. Alibaba Cloud also reduces the boot time of RunV containers. This guarantees the overall performance of the Kata Containers solution. Container Service for Kubernetes also supports clusters that provide sandboxed runtimes, which offer almost the same user experience as normal clusters. This enables you to run applications in lightweight sandboxed environments, which are suitable for workload isolation among multiple tenants and untrusted application isolation. Sandboxed containers enhance security and have little impact on application performance.
- Node autoscaling optimization
Aliyun Linux 2 dramatically speeds up system boot time of ECS instances. Compared with CentOS 7, the average system boot time is reduced by 29%. Based on autoscaling, clusters can quickly create and start ECS nodes when system overload is detected, and then schedule and start application instances accordingly. Aliyun Linux 2 enables quick startup of cluster nodes, which helps scale up computing resources to meet unexpected traffic spikes in a timely manner.
- CoreDNS optimization
When pods are densely deployed in a cluster, DNS resolution failures tend to occur because UDP connections account for too many entries in the conntrack table. Aliyun Linux 2 has optimized the conntrack table to reduce table entries by 50% when the DNS query rate is the same. This significantly improves the success rate of DNS queries.
- Resource monitoring and control
The kernel of Aliyun Linux 2 provides fine-grained visualization and control capabilities for containers, such as PSI pressure metrics, per-cgroup kswapd, and memory priority. In Kubernetes clusters based on Aliyun Linux 2, you can use CGroup Controllers to utilize these capabilities and implement fine-grained configurations and dynamic updates of resources such as BufferIO Control, TCP, CPUSet, Mem, and NUMA. This minimizes the interference among applications while steadily improving resource utilization.
- AI task and data processing acceleration
Aliyun Linux 2 optimizes large-scale instances to speed up the processing of high performance computing tasks and refines stream read/write methods to enhance large file read/write performance. This significantly improves the efficiency of processing AI and high performance computing tasks. The following data is recorded in test environments:
- Test: Use Alluxio to load 1,152 files that add up to 144 GB of OSS data through 64 threads. It takes CentOS 3 minutes and 25 seconds while Aliyun Linux 2 only needs 2 minutes and 19.037 seconds, which is 1.6 times the performance of CentOS.
- Test: Train the ResNet50 model with a batch size of 128 and cache data to Alluxio. In CentOS with NVIDIA V100, the speed is 5,212.00 images/s. In Aliyun Linux 2 with NVIDIA V100, the speed is 8,746.59 images/s, which is 1.7 times the performance of CentOS.
- Other features
- Based on Linux kernel 4.19, Container Service for Kubernetes integrates Aliyun Linux 2 with core capabilities and containerization best practices of Alibaba Group.
- Reduces the performance loss of OverlayFS and minimizes the storage performance decrease caused by containerization.
- Most sysctls are namespaced. In Kernel 4.19, most sysctls can be set independently on pods, which enables you to set different TCP timeout values and retransmit timeout values for different applications. You cannot modify these parameters in CentOS 7 while in Aliyun Linux 2, you can set these parameters on pods.
How to set node OS image to Aliyun Linux 2
When you create a cluster in the console, set Operating System to AliyunLinux 2.1903. For more information, see Create an ACK cluster.