Creating an Alarm Rule to Monitor a Server
To monitor the resource usage for servers, you can access the Server Monitoring page and create alarm rules and configure alarm notifications for specified resources. In this way, you will be notified immediately after the set thresholds are reached. This topic describes how to create an alarm rule to monitor specified resources of an ECS or BMS.
Alarm notifications sent by SMN will be billed based on their frequency and message length. For details, see Product Pricing Details.
Procedure
- Log in to the Cloud Eye console.
- In the navigation pane, choose Server Monitoring > Elastic Cloud Server (or Bare Metal Server).
- Locate the target ECS or BMS and choose More > Create Alarm Rule in the Operation column.
- On the Create Alarm Rule page, configure parameters.
- Configure the alarm rule name, description, and associated enterprise project.
Table 1 Parameter description Parameter
Description
Name
Alarm rule name. The system generates a random name, which you can modify. The rule name cannot exceed 128 characters and can contain only letters, digits, underscores (_), and hyphens (-).
Example value: alarm-b6al
Description
(Optional) Alarm rule description. It can contain up to 256 characters.
- Select monitored objects and configure alarm parameters.
Table 2 Parameter description Parameter
Description
Example Value
Alarm Type
Alarm type that the alarm rule applies to. The default value is Metric.
Metric
Cloud Product
Name of the monitored service. By default, it is the cloud service that the selected resource belongs to.
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.
When you create an alarm rule for a specified resource in Server Monitoring, the resource level is set to Cloud product by default.
Cloud Product
Monitoring Scope
Monitoring scope the alarm rule applies to.
When you create an alarm rule for a specified resource in Server Monitoring, the monitoring scope is set to Specific resources by default.
Specific resources
Instance
You do not need to set this parameter because it is the resource you selected.
-
Method
Method for configuring an alarm policy. The options are as follows:
- Configure manually: You can create a custom alarm policy as needed.
- Associate template: If you need to configure the same alarm rule for multiple groups of resources under the same cloud product, you can use an alarm template to simplify operations.
Configure manually
Template
Select the template to be imported. This parameter is mandatory when Method is set to Associate template.
You can select a default or custom template.
-
Alarm Policy
When you set Method to Configure manually, you need to configure alarm policies.
For example, an alarm is triggered if the average CPU usage of the monitored object is 80% or more for three consecutive 5-minute periods. Cloud Eye triggers an alarm every one hour again if the alarm persists.
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 Alarm Policies.
For details about basic and OS monitoring metrics, see Cloud Product Metrics.
NOTE:If the alarm is not cleared after it is generated, an alarm notification is sent, once every hour.
-
- Configure alarm notifications.
Table 3 Parameters for configuring alarm notifications Parameter
Description
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.
Notified By
Notification method. You can select Notification policies, Notification groups, or Topic subscriptions.
- Notification policies: If several O&M owners handle service maintenance, you can set up different notification scopes in a notification policy to alert specific owners by alarm severity or at a specified schedule. For details, see Creating a Notification Policy.
- Notification groups: You can create a notification group and add recipients to the group to centrally send them alarm notifications. For details, see Creating a Recipient and Notification Group.
- Topic subscriptions: If the current region does not support alarm notifications or the recipients have been configured in SMN, you can select a topic created in SMN and your cloud account contact as required.
NOTE:Cloud Eye uses SMN for alarm notifications. If SMN has major delays, the alarm notifications may also be delayed.
Notification Policies
If Notified By is set to Notification policies, you need to select one or more notification policies. You can specify the notification group, window, template, and other parameters in a notification policy. For details, see Creating, Modifying, or Deleting a Notification Policy.
Notification Group
Notification group for receiving alarm notifications. 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.
- The account contact is the mobile number and email address of the registered account.
- A topic is used to publish messages and subscribe to notifications. If the required topic is unavailable, create one and add subscriptions to it on the SMN console. For details, see Creating a Topic and Adding Subscriptions. For the HTTP/HTTPS messages, see Simple Message Notification User Guide.
Notification Templates
This parameter is only available if you set Notified By to Notification groups or Topic subscriptions. You can select an existing template or create one to send alarm notifications.
NOTE:Some cloud services do not support fields such as the resource name, enterprise project, resource tag, private IP address, and public IP address in the notification template. When you select a system template as the notification template, these fields will appear blank in the alarm notifications even if you have them configured.
Notification Window
Notification window during which Cloud Eye only sends notifications.
If you set this parameter to 08:00 to 20:00, Cloud Eye only sends notifications within this period.
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.
Trigger Condition
Condition that will trigger an alarm notification. You can select Generated alarm (when an alarm is generated), Cleared alarm (when an alarm is cleared), or both.
- Configure parameters in Advanced Settings.
Figure 1 Advanced settings
Table 4 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.
Tag
Each tag is a key-value pair. You can tag cloud resources to easily categorize and search for them. 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.
- A key can contain up to 128 characters, and a value can contain up to 225 characters.
- You can create up to 20 tags.
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.
- Click Create.
- Configure the alarm rule name, description, and associated enterprise project.
After the alarm rule is created, if a metric reaches the specified threshold, Cloud Eye immediately informs you of the exception through SMN.
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