Creating an Alarm Rule and Notifications
To monitor the usage of cloud service resources or key operations on them, you can create an alarm rule. After the alarm rule is created, if a metric reaches the specified threshold or the specified event occurs, Cloud Eye immediately informs you of the exception through SMN.
This topic describes how to create an alarm rule.
Alarm notifications sent by SMN will be billed based on their frequency and message length. For details, see Product Pricing Details.
Prerequisites
|
Alarm Type |
Prerequisites |
|---|---|
|
Metric |
|
|
Event |
Before creating an alarm rule for a custom event, ensure that the event source is the same as that specified in Reporting Events. |
Creating an Alarm Rule
- Log in to the Cloud Eye console.
- In the navigation pane, choose Alarm Management > Alarm Rules.
- Click Create Alarm Rule in the upper right corner.
- On the Create Alarm Rule page, configure parameters.
Assume that you want to notify all recipients in the notification group Notification_Group every hour when the raw data of CPU usage of any ECS exceeds 80% for three consecutive periods. In this case:
- Set Alarm Type to Metric.
- Set Cloud Product to Elastic Cloud Server - ECSs.
- Set Resource Level to Cloud product.
- Set Monitoring Scope to All resources.
- Set Method to Configure manually and set an alarm policy to trigger Hourly alarms when Raw data of ECSs / CPU Usage > 80% (marked as Major) for 3 times (consecutively).
- Enable Alarm Notifications and set Notified By to Notification groups.
- Select Notification_Group for Notification Group. Retain the default values for other parameters or leave them blank.
- Click Create.
Basic Parameters of an Alarm Rule
|
Parameter |
Description |
|---|---|
|
Name |
Name of the alarm rule. The name is automatically generated, but you can change it to a custom one. The rule name cannot exceed 128 characters and can contain only letters, digits, underscores (_), and hyphens (-). |
|
Description |
(Optional) Alarm rule description. It can contain up to 256 characters. |
Parameters of the Alarm Content
The alarm content parameters vary depending on the alarm type. You can check the parameter description based on the selected alarm type.
When setting Alarm Type to Metric, you can configure the alarm content by referring to the following table.
|
Parameter |
Description |
Example Value |
|---|---|---|
|
Cloud Product |
Name of the monitored service. For details about supported cloud products and their metrics, see Cloud Product Metrics. |
Elastic Cloud Server - ECSs |
|
Resource Level |
Resource level of the monitored object. You can select Cloud product or Specific dimension. Cloud product is recommended. Take ECS as an example. ECS is the cloud product. Specific dimensions are disks, mount points, processes, and more.
NOTE:
If you select Cloud product, metrics across dimensions (such as Disk Usage and CPU Usage) can be configured in the same alarm rule. If you select Specific dimension, only metrics of the specified dimension can be configured for the same alarm rule. |
Cloud product |
|
Monitoring Scope |
Monitoring scope the alarm rule applies to. You can select Resource groups, All resources, or Specific resources.
|
Specific resources |
|
Group |
When Monitoring Scope is set to Resource groups, you need to select a group. If no resource group meets your needs, click Create Resource Group to create one. After selecting a resource group from the drop-down list, you can click View Resources in a Group to view the details of resources in the group. After an alarm rule is configured, the group cannot be modified.
NOTE:
If the resource group contains an EVS resource with the type in the format of ECS instance ID-volume-Volume ID, the instance cannot report monitoring data after the alarm rule is created. As a result, no alarm can be triggered. |
- |
|
Instance |
When Monitoring Scope is set to Specific resources, you need to select the monitored objects for the alarm rule. Click Select Specific Resources to select desired resources. |
- |
|
Threshold Type |
For ECSs, you can select Static or Dynamic. The feature is available only in the CN South-Guangzhou region.
|
Static |
|
Method |
Mode for configuring an alarm policy. You can select Associate template or Configure manually.
|
Configure manually |
|
Template |
When you set Method to Associate template, you need to select a template. You can select a default or custom template.
NOTE:
An alarm template may contain alarm policies of multiple cloud products or different dimensions of the same cloud product. When you create an alarm rule, the alarm policies vary according to the resource level.
|
- |
|
Alarm Policy |
When you set Method to Configure manually, you need to configure alarm policies. You can add up to 50 alarm policies for a single alarm rule. You can choose to send alarm notifications when any of the policies is met or when all policies are met. For details about alarm policy parameters, see Configuring Alarm Policies for Metrics. You can customize alarm policy parameters or select Use Template to select an alarm template and modify the alarm policies in that template. Changes made will not affect the original policies in that template. An alarm will be triggered when the monitored data reaches the threshold the specified consecutive times. For example, Cloud Eye triggers a major alarm if the average CPU usage of the monitored object is 80% or more for three consecutive 5-minute periods. |
- |
|
Operation |
If there are multiple alarm policies, you can click Delete to delete one. |
Delete |
When setting Alarm Type to Event, you can configure the alarm content by referring to the following table.
|
Parameter |
Description |
Example Value |
|---|---|---|
|
Event Type |
This parameter is only available if Alarm Type is set to Event. You can select either System event or Custom event. For details about the events supported by each cloud service, see Events Supported by Event Monitoring. |
System event |
|
Event Source |
This parameter is only available if Alarm Type is set to Event.
|
Elastic Cloud Server |
|
Monitoring Scope |
Monitoring scope the alarm rule applies to.
NOTE:
This parameter is available when Event Type is set to System event. Currently, Resource groups is only available for DDS, RDS, and DCS event alarms. |
Specific resources |
|
Group |
When Monitoring Scope is set to Resource groups, you need to select a group. If no resource group meets your needs, click Create Resource Group to create one. After selecting a resource group from the drop-down list, you can click View Resources in a Group to view the details of resources in the group. After an alarm rule is configured, the group cannot be modified. |
- |
|
Instance |
When Monitoring Scope is set to Specific resources, you need to select the monitored objects for the alarm rule. Click Select Specific Resources to select desired resources. |
- |
|
Method |
Method used to create an alarm rule. If you select System event for Event Type, Method can be Associate template or Configure manually. If you select Custom event for Event Type, only Configure manually is supported.
|
Configure manually |
|
Template |
When you set Method to Associate template, you need to select a template. You can select a default or custom template.
NOTE:
An alarm template may contain alarm policies of multiple cloud products or different dimensions of the same cloud product. When you create an alarm rule, the alarm policies vary according to the resource level.
|
- |
|
Alarm Policy |
When you set Method to Configure manually, you need to configure alarm policies. You can add up to 50 alarm policies for a single alarm rule. You can choose to send alarm notifications when any of the policies is met or when all policies are met. For details about alarm policy parameters, see Configuring Alarm Policies for Events. You can customize alarm policy parameters or select Use Template to select an alarm template and modify the alarm policies in that template. Changes made will not affect the original policies in that template. The event that triggers an alarm is an instant operation. For example, an alarm is triggered if a VM is restarted. |
- |
|
Operation |
If there are multiple alarm policies, you can click Delete to delete one. |
Delete |
Alarm Notification Parameters
If no notification is received after alarm notification is enabled, rectify the fault by referring to Why Do Subscribers Fail to Receive Messages After I Publish Messages to a Topic?
|
Parameter |
Description |
Example Value |
|---|---|---|
|
Alarm Notifications |
Whether to send alarm notifications by SMS, email, FunctionGraph (function), FunctionGraph (Workflow), WeCom, DingTalk, Lark, WeLink, HTTP, or HTTPS. This parameter is enabled by default. |
Enabled |
|
Notified By |
Notification method. You can select Notification groups or Topic subscriptions.
NOTE:
Cloud Eye uses SMN for alarm notifications. If SMN has major delays, the alarm notifications may also be delayed. |
Notification groups |
|
Notification Group |
If Notified By is set to Notification groups, you need to select the notification groups to which alarm notifications will be sent. For details, see Creating a Recipient and Notification Group. |
- |
|
Recipient |
Target recipient of alarm notifications. You can select the account contact or a topic. This parameter is available only if Notified By is set to Topic subscriptions. If there is a display name of a topic, the format is Topic name (Display name), and you can search for a topic by name or display name. If no display name is set for a topic, only the topic name will be displayed.
|
Account contact |
|
Notification Window |
If Notified By is set to Notification groups or Topic subscriptions, you need to set the notification window. Cloud Eye sends notifications only within the validity period specified in the alarm rule. For example, if the notification window is set to 08:00:00 to 20:00:00, notifications are sent only within this specified time range when a metric reaches the specified threshold or a specified event occurs. |
08:00-20:00 |
|
Time Zone |
Time zone for the alarm notification window. By default, it matches the time zone of the client server, but can be manually configured. |
(GMT+08:00) Beijing, Chongqing, Hong Kong, Urumqi, Kuala Lumpur, Singapore, Perth, Taipei, Irkutsk, Ulaanbaatar |
|
Trigger Condition |
This parameter is required when you set Notified By to Notification groups or Topic subscriptions.
|
Generated alarm |
Parameters of Advanced Settings
|
Parameter |
Description |
|---|---|
|
Enterprise Project |
Enterprise project that the alarm rule belongs to. Only users with the enterprise project permissions can manage the alarm rule. For details about how to create an enterprise project, see Creating an Enterprise Project. |
|
Tags |
Key-value pairs that you can use to easily categorize and search for cloud resources. You are advised to create predefined tags in TMS. For details, see Creating Predefined Tags. If you have configured tag policies for Cloud Eye, add tags to alarm rules based on the tag policies. If you add a tag that does not comply with the tag policies, alarm rules may fail to be created. Contact your administrator to learn more about tag policies.
|
|
No-Data Processing |
If Alarm Type is set to Metric or WAN, you can configure whether to trigger alarms when no data is reported. This parameter is selected by default. If selected, an alarm record will be generated if the configured metric reports no data for three consecutive hours. |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot