This topic describes how to create a monitoring task. You can create metric-based monitoring tasks to trigger scaling activities upon emergent or unpredictable business changes. After you create and enable a monitoring task, Auto Scaling collects monitoring data for the specified metric in real time. When the specified condition is met, Auto Scaling executes the specified scaling rule to scale Elastic Compute Service (ECS) instances in the scaling group.


  1. Log on to the Auto Scaling console.
  2. In the left-side navigation pane, choose Scaling Tasks > Event-Triggered tasks.
  3. In the top navigation bar, select a region.
  4. Click Create Event-Triggered Task.
  5. In the dialog box that appears, set parameters for the monitoring task.
    1. Enter the name of the monitoring task.
      The name must be 2 to 64 characters in length. It must start with a letter or digit. It can contain periods (.), underscores (_), and hyphens (-).
    2. Enter the description of the monitoring task.
    3. Select the resource to be monitored.
      Select the scaling group to be monitored by the monitoring task.
    4. Select the monitoring type.
      The monitoring type cannot be changed after the monitoring task is created.
      • If you select System Monitoring, select a built-in metric of CloudMonitor. For more information about supported metrics, see System monitoring alarm tasks.
      • If you select Custom Monitoring, select the application group, metric, and dimension that are preconfigured in CloudMonitor. For more information about custom metric-based monitoring tasks, see Custom monitoring alarm tasks.
    5. Set the reference period.
      You can set the reference period to 1 minute, 2 minutes, 5 minutes, or 15 minutes. Auto Scaling collects, summarizes, and compares data based on the specified reference period. The monitoring task triggers alerts more frequently if the reference period is shorter. Set the reference period based on your business requirements.
    6. Set the trigger condition.
      Set the condition for triggering alerts. Select Average, Max, or Min, specify an operator, and enter the threshold. For example, if the metric is CPU usage and the upper limit is 80%, you can set one of the following conditions:
      • Average: The average CPU usage of the ECS instances in the scaling group exceeds 80%.
      • Max: The highest CPU usage among the ECS instances in the scaling group exceeds 80%.
      • Min: The lowest CPU usage among the ECS instances in the scaling group exceeds 80%.
    7. Specify the number of times the condition is met before an alert is triggered.
      You can set the Trigger After parameter to 1 Times, 2 Times, 3 Times, or 5 Times. Auto Scaling counts the number of times the condition is met. When the number of times reaches the value of the Trigger After parameter, Auto Scaling triggers an alert and executes the scaling rule specified in the monitoring task.
    8. Set the triggered rule.
      Select the scaling rule to be executed when the condition is met for the specified number of times. You can only select a scaling rule of the monitored scaling group.
  6. Click OK.