Clone a vertical scaling task

Updated at:

To quickly create a vertical scaling task, clone an existing one and modify its configuration.

Procedure

  1. Go to the vertical scaling page.

    1. Log on to the Auto Scaling console.

    2. In the navigation pane on the left, click Vertical Scaling.

    3. In the top navigation bar, select a region.

  2. Find the target vertical scaling task and click Clone in the Actions column.

  3. On the Clone Vertical Scaling Task page, modify the task configuration.

    The following table describes the task parameters.

    Parameter

    Description

    Task Type

    The scaling direction:

    • Upgrade: Upgrades the instance type to increase computing power.

    • Downgrade: Downgrades the instance type to reduce computing power.

    Select Instance

    The instance to which the task applies.

    Select Instance Type

    The target instance types. If you specify multiple types, the task scales the instance to each type in the specified order.

    Important

    Vertical scaling tasks can only adjust instance types within the same instance family.

    • Scale-up instance types: Specify up to 10 instance types in ascending order of computing power. The vCPU and memory of a subsequent instance type must be greater than those of the previous instance type.

      For example, the current instance type is ecs.g6.large. You specify ecs.g6.3xlarge, ecs.g6.4xlarge, and ecs.g6.6xlarge in this order. If two consecutive scale-up tasks run successfully, the instance type changes to ecs.g6.4xlarge.

    • Scale-down instance types: Specify up to 5 instance types in descending order of computing power. The vCPU and memory of a subsequent instance type must be less than those of the previous instance type.

      For example, the current instance type is ecs.g6.6xlarge. You specify ecs.g6.4xlarge, ecs.g6.3xlarge, and ecs.g6.large in this order. If three consecutive scale-down tasks run successfully, the instance type changes to ecs.g6.large.

    Trigger Type

    The method to trigger the task. Valid values:

    • Scheduled Trigger: You must specify the frequency and time for the task to run.

      • One-time execution: Select Execute Now, or select Executed Once at the Specified Time and then configure an execution time.

      • Recurring execution: Select Executed Periodically and then configure the recurrence frequency, time zone, and end time.

        Click Quick Selection to configure the recurrence frequency in the UI, or specify a cron expression. For more information about cron expressions, see Cron expressions.

        Important

        Vertical scaling restarts your pay-as-you-go instance, which causes service interruptions. We recommend that you schedule the task during off-peak hours.

    • Threshold Trigger: You must specify a threshold-based rule and a trigger silence period.

      • Rule: Define a threshold condition for a CloudMonitor metric. A threshold-based rule includes the metric name, aggregation period, number of consecutive periods, statistical method, comparison operator, and threshold.

        For example, to trigger a vertical scaling task when the average DiskIOPSWrite metric exceeds 70 count for three consecutive 5-minute periods, set Metric to DiskIOPSWrite, Aggregation Period to 5 Minutes, Consecutive Periods to 3, Method to Average, Comparison Operator to >, and Threshold to 70 (Unit: count).

      • Trigger Silence Period: If monitoring data continuously exceeds the alert threshold, only one task runs during the silence period.

        Important

        Configure threshold conditions with caution. If the number of consecutive periods is too small or the silence period is too short, your ECS instance may restart frequently, which can affect your services.

    Permissions

    Grant permissions to the RAM role that CloudOps Orchestration Service (OOS) uses.

    • If this is your first time using vertical scaling, create a RAM role for OOS and grant it permissions to manage ECS and Auto Scaling resources. For more information, see Create a RAM role for a trusted Alibaba Cloud service and Grant permissions to a RAM role.

      Note

      We recommend that you attach the AliyunECSFullAccess and AliyunESSFullAccess policies.

    • If you have used vertical scaling before, select an existing RAM role, such as OOSServiceRole.

    Advanced

    Optional. Add a description and tags to identify and manage the task.

  4. Click Create Vertical Scaling Task.

Result

After the vertical scaling task is created, the system executes the task at the specified time or when the threshold condition is met. Operations such as stopping the instance, changing the instance type, and restarting the instance are automatically performed. You can view the execution details of the task. For more information, see View vertical scaling tasks.