This topic describes how to execute scaling rules either manually or automatically to scale ECS instances.

Prerequisites

Before you execute a scaling ruling, note that:

  • The status of the scaling group to which the scaling rule belongs is in the Active state.
  • The scaling group to which the scaling rule belongs is not undergoing any scaling activities.
  • Target tracking scaling rules can only be executed by alert tasks that were automatically created. For more information, see Create a scaling rule.
  • There is no limit to the maximum number of ECS instances that a scaling group can have. However, the limits on ECS instance usage apply to Auto Scaling. For more information, see Limits.

Manually execute a scaling rule

If you need to scale ECS instances temporarily, you can manually execute a scaling rule.
Note If the scaling group is not undergoing any scaling activities, you can immediately execute the scaling rule without the need to wait for the cooldown period to expire.
  1. On the Scaling Rules page, click Execute in the Actions column corresponding to the scaling rule that you want to execute.
  2. In the Run Scaling Rule message that appears, click OK.
  3. If the scaling rule is executed, a prompt appears in the upper-right corner of the page.

    If the scaling rule fails to be executed, an error message appears in the center of the page.



  4. You can go to the Scaling Activities page to view the results of the scaling rule execution.

Execute a scaling rule by using a scheduled task

There are services that use ECS instances on a regular basis. For these services, you can specify a scaling rule when you create a scheduled task. Then, Auto Scaling executes this scaling rule at the scheduled points in time.



Execute a scaling rule by using an alert task

There are services that do not use ECS instances on a regular basis. For these services, you can specify a scaling rule when you create an alert task. Then, Auto Scaling automatically executes this scaling rule when the conditions specified in the alert task are met.

Alert tasks include system monitoring alert tasks and custom monitoring alert tasks, which meet monitoring requirements in different scenarios. For more information, see Auto Scaling alert tasks.


Set a system monitoring alert task
Set a custom monitoring alert task