Container Service for Kubernetes (ACK) provides the cluster diagnostics feature. This feature allows you to troubleshoot node, pod, and network issues in an ACK cluster. This topic describes how to use the cluster diagnostics feature to diagnose an ACK cluster.
Prerequisites
- An ACK cluster is created. For more information, see Create an ACK managed cluster.
- The ACK cluster is running as expected.
You can log on to the Container Service for Kubernetes (ACK) console, navigate to the Clusters page, and check whether the status of the cluster is Running.
Scenarios
You have located the pod, node, or network where the issue occurs:
- For Node diagnosis or Pod diagnosis, you need only to click Diagnose to obtain the diagnostic result and suggestions. You can also set parameters in the diagnostics panel to perform a diagnostic and then obtain the diagnostic result and suggestions.
- For Network diagnosis, you can set parameters in the diagnostics panel to perform a diagnostic and then obtain the diagnostic result and suggestions.
Procedure
- Log on to the ACK console.
- In the left-side navigation pane of the ACK console, click Clusters.
- On the Clusters page, find the cluster that you want to manage and click the name of the cluster or click Details in the Actions column. The details page of the cluster appears.
- You can select Node diagnosis, Pod diagnosis, or Network diagnosis based on your requirements:
- Node diagnosis
- Method 1:
- In the left-side navigation pane of the details page, choose Nodes > Nodes.
- Find the node that you want to diagnose and choose More > Exception Diagnosis in the Actions column.
You are directed to the Container Intelligence Service console and the system starts to diagnose the node.
- Method 2
- In the left-side navigation pane of the details page, choose Operations > Cluster Check.
- In the left-side navigation pane of the Container Intelligence Service page, choose Cluster Check > Diagnosis.
- On the Diagnosis page, click Node diagnosis.
- In the Select node panel, enter the node name, select I know and agree, and then click Create diagnosis.
Parameter Description Node name The name of the node that you want to diagnose. Example: cn-hangzhou.10.160.XX.XX
.
- Method 1:
- Pod diagnosis
- Method 1:
- In the left-side navigation pane of the details page, choose Workloads > Pods.
- In the top navigation bar, select a namespace from the Namespace drop-down list.
- Find the pod that you want to diagnose and click Diagnose in the Actions column.
You are directed to the Container Intelligence Service console and the system starts to diagnose the pod.
- Method 2
- In the left-side navigation pane of the details page, choose Operations > Cluster Check.
- In the left-side navigation pane of the Container Intelligence Service page, choose Cluster Check > Diagnosis.
- On the Diagnosis page, click Pod diagnosis.
- In the Select Pod panel, set the following parameters, select I know and agree, and then click Create diagnosis.
Parameter Description Pod Namespace The namespace to which the pod that you want to diagnose belongs. Pod Name The name of the pod that you want to diagnose.
- Method 1:
- Network diagnosis
- In the left-side navigation pane of the details page, choose Operations > Cluster Check.
- In the left-side navigation pane of the Container Intelligence Service page, choose Cluster Check > Diagnosis.
- On the Diagnosis page, click Network diagnosis.
- In the Network panel, set the following parameters, select I know and agree, and then click Create diagnosis.
Parameter Description Source address The source IP address. Destination address The destination IP address. Destination port The destination port. Enable packet tracing Specify whether to enable packet tracing. If you select Enable packet tracing, the host sends TCP or UDP packets and attempts to capture the packets on the network node that uses the destination IP address. The host locates the route on which packets are dropped based on the destination that the packets actually arrive. It requires 1 to 5 minutes to complete the packet tracing.
Notice When the system performs a diagnostic, the system runs a process on a cluster node to collect data and diagnostic result. Information about the operating system version, loads, Docker, kubelet and other components, and key error messages in the system log is collected. The system does not collect information related to the business or sensitive data. - Node diagnosis
- In the list of diagnostic records, find the diagnostic record that you want to manage
and click Diagnosis details in the operation column. The following table describes the details about the diagnostics.
Item Page Flag Description Node diagnosis - Normal
: No operations are required.
- Warning
: Confirm the severity of the issue. Troubleshoot the issues that may cause cluster anomalies.
- Abnormal
: Troubleshoot the issues at the earliest opportunity to avoid cluster errors.
- Unknown
: The diagnostic may not be completed or the diagnostic result is unknown.
The details page of the diagnostic displays the diagnostic result, suggestions, and diagnostic items. - Move the pointer over the
icon to the right side of a diagnostic item to view information about the diagnostic item.
- Diagnostic items with the Abnormal or Warning flag are displayed on the Troubleshoot tab.
- When a diagnostic item displays the Abnormal flag, you can move the pointer over Details in the Status column to view details about the exception.
- Node diagnostics includes the Node, NodeComponent, and ClusterComponent diagnostic items. The system locates the causes of node exceptions based on the status of the Elastic Compute Service (ECS) instance, node, and cluster components, and the information collected from the node. You can view the diagnostic items on the details page of the diagnostic.
Pod diagnosis Pod diagnostics includes the Pod, Node, NodeComponent, and ClusterComponent diagnostic items. The system locates the causes of pod exceptions based on the status of the pod, node, and cluster components. You can view the diagnostic items on the details page of the diagnostic. Network diagnosis N/A You can view details about the network diagnostic based on the diagnosis result, packet paths, and all possible paths. - Normal