This topic describes how to integrate Alibaba Cloud Managed Service for Prometheus into a Container Service for Kubernetes (ACK) cluster, view the dashboards, and configure alert rules for the cluster.
Prerequisites
Managed Service for Prometheus is activated. For more information, see Billing overview.
An ACK cluster is created. For more information, see Create an ACK managed cluster.
Alibaba Cloud Resource Center is activated. For more information, see Activate Resource Center.
Step 1: Integrate Managed Service for Prometheus into the ACK cluster
Managed Service for Prometheus allows you to integrate the monitoring capabilities into ACK. You can use one of the following methods based on your business requirements.
Method 1: Use the ACK console
Integrate Managed Service for Prometheus into a new cluster
When you create a new ACK cluster, you can enable the monitoring capabilities of Managed Service for Prometheus.
Integrate Managed Service for Prometheus into an existing cluster
You can perform the following steps to integrate Managed Service for Prometheus into an existing cluster:
Log on to the ACK console. In the left-side navigation pane, click Clusters.
On the Clusters page, find the cluster that you want to manage and click its name. In the left-side pane, choose .
On the Prometheus Monitoring page, click Install.
NoteThe system automatically installs the ack-onepilot component and checks the dashboards. After the installation is complete, click each tab to view the monitoring data.
After Managed Service for Prometheus is integrated into the ACK cluster, the dashboard data is updated within 1 to 2 seconds.
Method 2: Use the ARMS or Managed Service for Prometheus console
You can use the ARMS or Managed Service for Prometheus console to integrate Managed Service for Prometheus into a cluster. The procedures are similar. This section uses the ARMS console as an example.
In the left-side navigation pane, click Integration Center.
On the Integration Center page, click Infrastructure. In the Infrastructure section, click Kubernetes Cluster Monitor.
On the Start Integration tab of the Kubernetes Cluster Monitor panel, select the ACK cluster and click OK.
After Managed Service for Prometheus is integrated into the ACK cluster, the dashboard data is updated within 1 to 2 seconds.
Step 2: View the dashboards
Managed Service for Prometheus provides multiple built-in dashboards, including cluster overview, core components, nodes, and pods. You can view these dashboards in the ACK, ARMS, or Managed Service for Prometheus console. You can use one of the following methods based on your business requirements.
Method 1: View the dashboards in the ACK console
Log on to the ACK console. In the left-side navigation pane, click Clusters.
On the Clusters page, find the cluster that you want to manage and click its name. In the left-side pane, choose .
On the Prometheus Monitoring page, click each tab to view the dashboard based on your business requirements.
Method 2: View the dashboards in the ARMS or Managed Service for Prometheus console
Log on to the ARMS console or the Managed Service for Prometheus console to view the dashboards of the cluster. The ARMS console is used as an example. Perform the following steps in the ARMS console:
In the left-side navigation pane, click Integration Management.
On the Integration Management page, click the Query Dashboards tab.
Select the ACK cluster to view the dashboards.
Step 3: Configure alerting
In the left-side navigation pane, click Integration Management.
On the Integrated Environments tab of the Integration Management page, click Container Service. In the ACK environment instance list, click the name of the ACK cluster to go to the environment instance details page.
On the Component Management tab, click Alert Rule in the Add-on Type section to view the built-in alert rules of Managed Service Prometheus.
The built-in alert rules generate alert events without sending alert notifications. If you want to send alert notifications by using emails or other channels, click Edit to configure the notification methods. On the Edit Prometheus Alert Rule page, you can configure custom alert thresholds, duration, and alert content. For more information, see Create an alert rule for a Prometheus instance.
If you set the Alert Notification parameter to Simple Mode, you can configure the contacts that receive alert notifications and the notification period, and specify whether alert notifications are repeatedly sent.