Alert rules let you monitor resource usage across your services. When a metric exceeds a specified threshold, CloudMonitor automatically sends a notification so you can quickly address cluster anomalies.
Background information
Alerting is provided by CloudMonitor. To manage alert rules or access additional monitoring features, go to the CloudMonitor console. For more information, see What is CloudMonitor?.
Prerequisites
A cluster is created. For more information, see Create a cluster.
Limits
RAM users must have the following permissions. To grant permissions to a RAM user, see Grant permissions to a RAM user.
{
"Version": "1",
"Statement": [
{
"Action": [
"cms:DescribeContactGroupList",
"cms:DescribeMetricMetaList",
"cms:PutResourceMetricRules",
"cms:DescribeMetricRuleList"
],
"Resource": "*",
"Effect": "Allow"
}
]
}
Create alert rules
From template
-
Go to the Alert Management page.
-
Log on to the E-MapReduce console.
-
In the top navigation bar, select a region and resource group based on your requirements.
-
On the EMR on ECS page, click the ID of your target Cluster ID.
-
Click the Monitoring and Diagnostics tab.
-
Click Alert Management.
-
-
On the Alert Management page, click Create Alert Rules.
-
In the Create Alert Rules panel, find the target service and click Create Alert Rules in the Actions column.
-
Configure the parameters and click create.
Parameter
Description
Rule Description
Lists the alert rules in the template. You can view metric names and modify default thresholds.
For information about the service scope and thresholds, see Template service scope.
Mute Period
The interval at which alert notifications are re-sent for unresolved alerts.
Validity Period
The time window during which the alert rule is active. CloudMonitor evaluates metrics only within this window.
Alert Contact Group
The alert contact group that receives notifications.
Notification method
The notification method and email subject. The following notification methods are available:
-
Phone call, Text message, Email, and DingTalk Chatbot
-
Text message, Email, and DingTalk Chatbot
-
Email and DingTalk Chatbot
Alert Email Subject (Optional): If you specify a subject, it is included in the alert notification email.
Callback URL (optional)
A publicly accessible callback URL. CloudMonitor sends a POST request with alert information to this URL. Only HTTP is supported.
After you create the alert rules, they take effect on the current instance. You can view them on the Alert Management page.
On the Alert Management page, click Manage Alert Rules to open the CloudMonitor console, where you can view or modify the rules.
-
Custom
-
Go to the Alert Management page.
-
Log on to the E-MapReduce console.
-
In the top navigation bar, select a region and resource group based on your requirements.
-
On the EMR on ECS page, click the ID of your target Cluster ID.
-
Click the Monitoring and Diagnostics tab.
-
Click Alert Management.
-
-
On the Alert Management page, click Create Alert Rules.
-
In the Create Alert Rules panel, click the Create Custom Rule tab.
-
Configure the parameters and click create.
Parameter
Description
Alert rule
The alert rule name and triggering condition.
The condition defines the metric thresholds and criteria that trigger the alert.
Note-
For a list of EMR metrics applicable to alert rules, see CloudMonitor metrics.
-
You can click Add Alert Rule to specify multiple rule conditions.
Mute period
The interval at which alert notifications are re-sent for unresolved alerts.
Effective period
The time window during which the alert rule is active. CloudMonitor evaluates metrics only within this window.
Alert contact group
The alert contact group that receives notifications.
Notification method
The notification method and email subject. The following notification methods are available:
-
Phone call, Text message, Email, and DingTalk Chatbot
-
Text message, Email, and DingTalk Chatbot
-
Email and DingTalk Chatbot
Alert Email Subject (Optional): If you specify a subject, it is included in the alert notification email.
Callback URL (optional)
A publicly accessible callback URL. CloudMonitor sends a POST request with alert information to this URL. Only HTTP is supported.
After you create the alert rule, it takes effect on the current instance. You can view it on the Alert Management page.
On the Alert Management page, click Manage Alert Rules to open the CloudMonitor console, where you can view or modify the rules.
-
View alert rules
The Alert Management page lists all alert rules you created.
|
Parameter |
Description |
|
Rule Name |
The CloudMonitor alert rule name. |
|
Status |
The alert rule status in CloudMonitor. Valid values: OK, Alert, Insufficient Data, Disabled, and Enabled. |
|
Rule Description |
The triggering conditions of the alert rule. An alert is triggered when metric data meets these conditions. |
|
Alert Contact Group |
The contact group that receives notifications. |
|
Actions |
|
Template service scope
|
Service |
Component |
Metric |
Description |
|
Node (host) |
Disk |
|
An alert is triggered if the average value is greater than 80% for 2 consecutive periods. The metric is checked every minute. |
|
CPU |
|
An alert is triggered if the average value is less than 5% for 5 consecutive periods. The metric is checked every minute. |
|
|
Memory |
|
An alert is triggered if the average value is greater than 90% for 2 consecutive periods. The metric is checked every minute. |
|
|
HDFS |
NameNode |
|
An alert is triggered if the average value is greater than 95% for 2 consecutive periods, or if no metric data is generated. The metric is checked every minute. |
|
NameNode |
|
An alert is triggered if the average value is greater than 1,000 for 2 consecutive periods. The metric is checked every minute. |
|
|
NameNode |
|
An alert is triggered if the average value is greater than 1 for 2 consecutive periods. The metric is checked every minute. |
|
|
NameNode |
|
An alert is triggered if the component enters safe mode. The metric is checked every minute. |
|
|
DataNode |
|
An alert is triggered if the average value is greater than 95% for 2 consecutive periods, or if no metric data is generated. The metric is checked every minute. |
|
|
Spark |
SparkHistoryServer |
|
An alert is triggered if the average value is greater than 95% for 2 consecutive periods. The metric is checked every minute. |
|
SparkThriftServer |
|
An alert is triggered if the average value is greater than 95% for 2 consecutive periods. The metric is checked every minute. |
|
|
Hive |
HiveMetaStore |
|
An alert is triggered if the average value is greater than 95% for 2 consecutive periods. The metric is checked every minute. |
|
HiveMetaStore |
|
An alert is triggered if the average value is greater than 50% for 2 consecutive periods. The metric is checked every minute. |
|
|
HiveServer2 |
|
An alert is triggered if the average value is greater than 95% for 2 consecutive periods. The metric is checked every minute. |
|
|
HiveServer2 |
|
An alert is triggered if the average value is greater than 50% for 2 consecutive periods. The metric is checked every minute. |
|
|
YARN |
ResourceManager |
|
An alert is triggered if two or more high availability (HA) switchovers occur within 5 minutes, if a node has a status of 1, or if a node's status remains -1. |
|
ResourceManager |
|
An alert is triggered if the average value is greater than 95% for 2 consecutive periods, or if no metric data is generated. The metric is checked every minute. |
|
|
NodeManager |
|
An alert is triggered if the average value is greater than 1 for 2 consecutive periods. The metric is checked every minute. |
|
|
NodeManager |
|
An alert is triggered if the average value is greater than 95% for 2 consecutive periods, or if no metric data is generated. The metric is checked every minute. |
|
|
TimelineServer |
|
An alert is triggered if the average value is greater than 95% for 2 consecutive periods, or if no metric data is generated. The metric is checked every minute. |
|
|
MRHistoryServer |
|
An alert is triggered if the average value is greater than 95% for 2 consecutive periods, or if no metric data is generated. The metric is checked every minute. |
|
|
ZooKeeper |
ZooKeeper |
|
An alert is triggered if the average value is greater than or equal to 10,000 for 2 consecutive periods. The metric is checked every minute. |
|
ZooKeeper |
|
An alert is triggered if the average value is greater than or equal to 1,000 for 2 consecutive periods. The metric is checked every minute. |
|
|
Kafka |
KafkaBroker |
|
An alert is triggered if the average value is greater than 0 for 2 consecutive periods. The metric is checked every minute. |
|
|
An alert is triggered if the average value is greater than 0 for 2 consecutive periods. The metric is checked every minute. |
||
|
Presto/Trino |
Trino |
|
An alert is triggered if the average value is greater than or equal to 1 for 2 consecutive periods. The metric is checked every minute. |
|
|
An alert is triggered if the average value is greater than 0 for 2 consecutive periods. The metric is checked every minute. |
||
|
Presto |
|
An alert is triggered if the average value is greater than or equal to 1 for 2 consecutive periods. The metric is checked every minute. |
|
|
|
An alert is triggered if the average value is greater than 0 for 2 consecutive periods. The metric is checked every minute. |
||
|
Impala |
Impalad |
|
An alert is triggered if the average value is greater than or equal to 10 for 2 consecutive periods. The metric is checked every minute. Note
You can adjust the threshold based on your cluster's query concurrency. |
|
Kudu |
kudu-master |
|
An alert is triggered if the average value is greater than or equal to 1,000 for 2 consecutive periods. The metric is checked every minute. Note
You can adjust the threshold based on your workload. |