All Products
Search
Document Center

Container Service for Kubernetes:Collect logs of control plane components in ACK Serverless clusters

Last Updated:May 31, 2024

You can collect logs of control plane components to manage your clusters in a more secure and efficient manner. Container Service for Kubernetes (ACK) allows you to collect logs of control plane components in ACK Serverless clusters to Simple Log Service projects of your account. This way, you can manage and analyze logs in a centralized manner.

Prerequisites

Your Alibaba Cloud account has a sufficient quota of Logstores in Log Service.

Note

The default Logstore quota of an Alibaba Cloud account is 50. To increase the quota, submit a ticket.

Enable the log collection feature for control plane components

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

  2. On the Clusters page, click the name of the cluster that you want to manage and choose Operations > Log Center in the left-side navigation pane.

  3. On the Log Center page, click the Logs of Control Plane Components tab and click Enable Component Log Collection.

    Wait for the system to install the log collection component. After the component is installed, the collected logs are displayed.

Query the logs of control plane components

You can query the logs of control plane components in the ACK console or Simple Log Service console.

Note

You can query the logs of the kube-apiserver, kube-controller-manager, and Cloud Controller Manager control plane components in ACK Serverless clusters. For more information, see Log search overview.

Query the logs of control plane components in the ACK console

You can use one of the following methods to query the logs of control plane components.

  • View the logs of control plane components in the Cluster Information module.

    1. On the cluster details page, click the Cluster Resources tab and click the URL of the Simple Log Service project.

    2. Select the Logstore that stores the logs of control plane components in the left-side Logstores list of the Log Storage page.

  • Query the logs of control plane components in the Operations module.

    1. In the left-side navigation pane of the cluster details page, choose Operations > Log Center.

    2. On the Log Center page, click the Logs of Control Plane Components tab. You can select a component and query its logs.

Query the logs of control plane components in the Simple Log Service console

  1. Log on to the Simple Log Service console.

  2. In the Projects section, click the name of the Simple Log Service project that stores the logs of the cluster.

  3. In the Logstores list of the Log Storage page, select the Logstore that stores the logs of control plane components.

Logstores that store the logs of control plane components

You can collect logs of the control plane component of the following types in ACK Serverless clusters. Each Simple Log Service Logstore stores the logs of a type of control plane component. For more information about the components, see Kubernetes Components.

Component

Logstore

Description

kube-apiserver

apiserver

kube-apiserver is a component of the Kubernetes control plane that exposes the Kubernetes API. For more information, see kube-apiserver.

kube-controller-manager

kcm

The kube-controller-manager component is the internal management and control center of a Kubernetes cluster. The component embeds the core control loops shipped with Kubernetes. For more information, see kube-controller-manager.

Cloud Controller Manager

ccm

Cloud Controller Manager allows you to integrate Kubernetes with Alibaba Cloud services, such as Classic Load Balancer (CLB) and Virtual Private Cloud (VPC). CLB is formerly known as Server Load Balancer (SLB). Cloud Controller Manager manages the features, such as load balancing and cross-node communication, that are provided by these services. For more information, see Cloud Controller Manager.

Disable log collection for control plane components

You can disable log collection for control plane components in the Operations menu in the ACK console.

  1. In the left-side navigation pane of the cluster details page, choose Operations > Log Center.

  2. Click the Logs of Control Plane Components tab. Then, click Close in the upper-right corner.

  3. In the message that appears, click OK.