Collect logs of control plane components to manage your clusters more securely and efficiently. Container Service for Kubernetes (ACK) lets you collect logs of control plane components in ACK Serverless clusters to Simple Log Service projects in your account. This enables centralized log management and analysis.
Prerequisites
Your Alibaba Cloud account has a sufficient quota of Logstores in SLS.
The collected logs are sent to the specified SLS projects of your account in the form of log streams. You are charged for SLS based on the pay-as-you-go billing method. For more information, see Pay-by-feature.
Enable the log collection feature for control plane components
Log on to the ACK console. In the left navigation pane, click Clusters.
On the Clusters page, find the cluster you want and click its name. In the left-side pane, choose .
On the Log Center page, click the Control Plane Component Logs tab and click Enable Component Log Collection.
Wait for the system to install the log collection component. After installation is complete, the collected logs will be displayed.
Query the logs of control plane components
You can query the logs of control plane components in either the ACK console or Simple Log Service console.
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.
View from the Container Service console
You can use one of the following methods to query the logs of control plane components.
Query the logs of control plane components in the Cluster Information module.
On the cluster details page, click the Basic Information tab, and click View next to Control Plane Component Logs.
On the Log Center page, select the component to view its logs.
Query the logs of control plane components in the Operations module.
In the navigation pane on the left of the cluster details page, choose .
On the Log Center page, click the Control Plane Component Logs tab. Select a component and query its logs.
Query the logs of control plane components in the Simple Log Service console
Log on to the Simple Log Service console.
In the Projects section, click the name of the Simple Log Service project that stores the logs of the cluster.
In the tab, click 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 lets you 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 the log collection feature for control plane components
You can disable the log collection feature for control plane components in the Operations module in the ACK console.
On the Clusters page, find the cluster you want and click its name. In the left-side pane, choose .
On the Log Center page, click the Control Plane Component Logs tab, then click Close.