Destination

When your Alibaba Cloud account has many resources such as servers and cloud products, how do you quickly create alert policies for these resources and modify improper alert policies? By presenting a specific case, this article provides large business users with guidance on using application grouping and alert template to manage the alert policies of cloud resources used by services.

Case studies

When your account has many servers and other cloud product instances, it is recommended that you create different application groups for these resources from the service perspective and then use application groups to manage resources in batches.

### How to improve the efficiency of alert policy configuration using an alert template?

  • The alarm rule configuration is different on apply grouping and configure on a single instance
    • + You can select "Instance" or "Application Group" for the resource range when creating an alert policy. If "Application Group" is selected, the alert policy takes effect for all resources in the application group. When your business needs to expand or shrink, you only need to move the appropriate resources into or out of the app grouping, without adding or removing alarm rules. After you modify an alert policy of the application group, the modified alert policy takes effect for all instances in the application group.
    • + If "Instance" is selected, the alert policy only takes effect for the target instance. After you modify the alert policy, it only takes effect for the instance. As the number of instances increases, management of alert policies becomes increasingly complex.
  • You can use the alert template function to improve the efficiency of alert policy configuration.
    • + Metrics and alert thresholds are relatively fixed during alert policy configuration for basic services such as ECS, ApsaraDB for RDS, and Server Load Balancer. After an alert template is created for monitoring indexes that require alerting, you can create an application group for new services and apply the alert template to the application group to create alert policies for the new services in one click.
    • + When you need to add, modify, or delete alert policies in batches, you can modify the alert template and then apply it to the application group. This can save plenty of time.

Procedure

The following describes how to create an application group for the background services of an e-commerce website and apply an alert template to the application group to quickly build a cloud-based monitoring and alerting system.

  1. The e-commerce website has background modules such as stock management, payment management, and item management. Follow the procedures below to complete this exercise. Create an application group named "Online Environment of Stock Management":
    • + Go to the [Application Group] page and click "Create Group" at the upper-right corner to go to the page for creating an application group.
    • + Name the application group and select the cloud resources used by the stock management service. The common combination of server+database+server load balancer is used as an example.
    • + Select a notification recipient. When an alert is triggered based on the alert policies of the application group, the alert information is sent to the selected notification recipient.
    • + Click "OK" to create the application group.
  2. Create an alert template:[/concept/conbody/section/ol/li/ul {"- topic/ol"})
  3. + Go to the [Alert Template] page and click "Create Alert Template" at the upper-right corner to go to the page for creating an alert template.
  4. + Fill out the alert template with the basic information.
  5. + Add the alert policies required by the service module to the alert template.
  6. + Click "OK" to save the template setting.
  7. (ul]
  8. Apply the alert template to the application group:

    + Select the created alert template in the template list and apply the alert template to the application group named "Online Environment of Stock Management". Configure the notification method.