View here to log in or access your console

OK

Auto Scaling

Auto Scaling automatically adjusts computing resources based on your business cycle

Get for Free

Auto Scaling

Auto Scaling is a service to automatically adjust computing resources based on your volume of user requests. When demand for computing resources increase, Auto Scaling automatically adds ECS instances to serve additional user requests, or alternatively removes instances in the case of decreased user requests.

This service is available free of cost. You will be only charged for the standard cost of adding additional ECS resources.


Customer Testimonials

Alibaba Cloud Auto Scaling dynamically adjusts computing resource with multiple scaling modes, this in turn significantly improves our system stability and reduces operation costs.


Benefits

Flexible

● Intelligent scheduling to support various scenarios.

● Automatically adjusts computing resources according to various scaling policies.

● Supports manual scale-in and scale-out, which offer you flexibility to control resources manually.

Automatic

● Automatic surveyance of health status.

● Automatically create or release ECS resources after scaling policy is triggered.

● Automatically configures load balancer and RDS whitelist.

Product Details

Auto Scaling is an Alibaba Cloud service that integrates with your business cycle to automatically adjust computing resources based on the volume of user requests. Auto Scaling also integrates with Server Load Balancer and CloudMonitor to ensure uninterrupted service and streamlined maintenance.

Elastic Scale-Out: During peak periods, Auto Scaling automatically adds additional computing resource to the pool.

Elastic Scale-In: When user requests decrease, Auto Scaling automatically releases ECS resources to cut down your costs.

Elastic Self-Health: When an unhealthy instance has been detected, the auto-scaling service automatically replaces the instance with a new one to ensure uninterrupted service.


Features

Auto Scaling

According to customer business needs, automatically increase or decrease ECS instances.

Support Server Load Balancer Configuration

When adding or releasing ECS instances, the service automatically attaches or detaches the instances to the Sever Load Balancer.

Support RDS White List

When adding ECS instances, the service automatically adds instance IPs to the white list of RDS instances. Likewise, when releasing ECS instances the service automatically delists instance IPs from the white list.

Scale Mode

Scheduled Mode

Configure scheduled tasks, and add or remove ECS instances with a fixed time window. Can be combined with dynamic mode.

Dynamic Mode

Based on CloudMonitor metrics (ie. CPU and memory ratio), dynamically add or remove ECS instance/s.

Fixed Mode

The “minimal size” setting allows you to employ the minimal ECS instances required to support business-as-usual levels of activity.

Auto-config Server Load Balancer and RDS

When adding or removing ECS instances, the service automatically attaches or detaches instances to the Server Load Balancer, and adds these servers to the white list of RDS instances.

Note

Auto Scaling is subject to the following constraints:

  • Applications that deploy Auto Scaling ECS instances must be stateless and horizontally scalable. ECS instances created by Auto Scaling cannot be used to save application status (ie. session status) or related data (ie. databases and logs). This is because Auto Scaling automatically releases ECS instances. Status information can be saved to an independent state server, database (ie. RDS), shared cache (ie OCS), or centralized log storage (ie. SLS).

  • Each user can only create a limited number of scaling groups, scaling configurations, scaling rules, scaling ECS instances, and scheduled tasks.

Note: Auto Scaling uses its best effort to ensure you are notified of the complete resources of normal scaling. However, due to insufficient ECS instance inventory, long startup time, and other issues, the full resources of scaling may not be displayed. Thank you for your understanding.

Development history

  • 8/27/2015: Auto Scaling product released

  • 10/15/2014: Auto Scaling product beta test


Pricing

Auto Scaling is offered to customers at no extra cost. You will only be charged for the ECS instances automatically created by or manually added to Auto Scaling. Note that you will still be charged for Pay-As-You-Go instances even after you stop them. You must release the instances to avoid further fees.


Customer Cases

Miao Pai

Miao Pai is a product of the Chinese app company XuanYixia which has become popular with celebrities and young people. Miao Pai is a video capture app which has various themes and camera for user to make their own short videos, and share with family and friends.

The Challenge

Miao Pai is attracting more and more users on the back of its simple user model, cool video effects and social sharing. However, as the number of users increases, a more significant concern now is how to ensure the quality of service during peak hours.

Why Auto Scaling?

As the domestic leader in cloud computing in the China market, Alibaba Cloud has helped to solve Miao Pai’s dynamic expansion problems with its Auto Scaling product. With the aid of Auto Scaling Miao Pai is able to manage various scaling policies and it automatically adjusts computing resources based on traffic cycles.

Getting Started

One-minute scaling solution creation

This quick start guide teaches you how to use a simple scaling solution in Auto Scaling to create an ECS instance, automatically add it to a Server Load Balancer instance, and automatically add the instance IP address to the RDS access white list.

To create a complete Auto Scaling solution, you must follow the two steps below:

Step 1: Create a scaling configuration

A scaling group is a collection of ECS instances with the same application scenarios. It defines the max and min numbers of ECS instances in the group, as well as their associated Server Load Balancer instances, RDS instances, and other attributes.

Operation procedure:

1. Select the "region" for the scaling group and enter the "scaling group name".

2. Set "Max number of instances allowed for scaling" and "Min number of instances allowed for scaling" to 1. This automatically creates one ECS instance after the overall scaling solution is created.

3. Select the "Sever Load Balancer" instance. Health check must be enabled for all the listener ports configured for the specified Server Load Balancer instance.

4. Select a "Database" instance to bring up the "Select RDS database" dialog box (as shown in the image: Select RDS database).

5. After making all the necessary selections, click "Next".

Step 2: Create a scaling configuration

A scaling configuration defines the configuration information of the ECS instances used for Auto Scaling. When automatically adding ECS instances to a scaling group, Auto Scaling will create the ECS instances based on the scaling configuration.

Operation procedure:

1. Choose a ECS template.

2. Enter the name of the scaling configuration.

3. Choose a security group.

4. Choose the bandwidth you need.

5. Click "Next" and go to confirm

Step 3: Preview configure detail page

The detail page shows the details of scaling configuration.

Three-minute scaling solution creation

This example will show you how to create and configure overall scaling solutions, including timed, dynamic, custom, and fixed mode scaling solutions. To create a complete Auto Scaling solution, you must follow the five steps below:

Step 1: Create a scaling configuration

Enter the basic scaling group information: "Region", "Scaling group name", "Max number of instances allowed for scaling", and "Min number of instances allowed for scaling". To use Server Load Balancer or RDS, select a "Server Load Balancer" or "Database" instance.

Step 2: Scaling group configuration

A scaling configuration defines the configuration information of the ECS instances used for Auto Scaling. When automatically adding ECS instances to a scaling group, Auto Scaling will create the ECS instances based on the scaling configuration.

Step 3: Auto scaling trigger settings

There are two auto scaling trigger methods:

  • Scheduled auto-scaling tasks

  • Auto-scaling task alarm triggers

Step 4: Scheduled auto scaling tasks

If recurrence is not set, the task is executed once on the designated date and time. Otherwise, the designated execution time defaults to be the time point executing this task periodically.

Step 5: Auto scaling task alarm trigger

Automatically increases or decreases the number of ECS instances in a scaling group based on CloudMonitor performance indicators (such as CPU and memory usage). For alarms to be triggered, the new version of CloudMonitor Agent must be installed in the ECS image.

Resources

Developer Resources

Related Services

FAQs

Environment configuration

How do I ensure the configuration environments are consistent for Auto Scaling ECS instances? Or, how do I directly add a previous system environment to the Auto Scaling instances?

When creating a scaling configuration for ECS instances, you can use an ECS custom image template to create instances. If you need to sync internal system data when the ECS instances are running, we suggest you install a custom rsync program.

In the created instances, why is 127.0.0.1 added after /etc/hosts cleared upon reset?

Currently, when you add your own content after /etc/hosts in an image and use the custom image generated by this image to create an instance, its configuration will be restored to the system default settings. Therefore, the added content will be cleared. If you need to keep these settings, you can add the script code in rc.local. Then, check if the information is in /etc/hosts. If not, you must add it again.

My Auto Scaling service is set up to automatically create instances and there is no fixed quantity. How can I ensure that my instances can be scaled normally when using images on the image market?

If you need to scale to 'x' number of instances that use the same image, you must first buy 'x' number of images from the image market.

Can I buy images from the image market in batches?

At present, batch purchasing is not supported.

If a previously used image from the image market no longer exists (for example, jxsc000010), how can I ensure that the scaling group instances I have set up can be scaled normally?

In this case, we suggest you select a suitable replacement image from the image market.

Can I use a single product code to get images from different regions?

Yes, so long as these regions support this image product.

I bought 100 images with the same product code. Can I use these images in all regions?

Currently, images in the image market have region attributes. You must buy images of your desired region.

Password and logon

When Auto Scaling automatically creates instances, how do I view their passwords and log on to these instances?

  • As instances automatically created by Auto Scaling do not provide the same logon password for Linux users, we recommend you set a public/private key certificate for SSH password-free logon.

  • If you do not want to set a public/private key certificate for SSH password-free logon, you must reset the password on the console (and then restart the instance to apply the new password) before you can logon.

Why are the passwords of instances produced by Auto Scaling different from the password in my custom image?

  • The created ECS instances do not have the same password as the custom image. To ensure password security, we recommend you set a public/private key certificate for SSH password-free logon.

  • If you do not want to set a public/private key certificate for SSH password-free logon, you must reset the password on the console (and then restart the instance to apply the new password) before you can log on.

Server Load Balancer and RDS

After Auto Scaling creates an ECS instance, will the new instance be automatically added to a Sever Load Balancer instance?

If a Server Load Balancer instance is specified in a scaling group, the scaling group will automatically add the ECS instances in the group to the specified Server Load Balancer instance.

When a scaling group is added in Auto Scaling, can I bind multiple Sever Load Balancer instances to the group?

By default, you can only bind one Server Load Balancer instance to each scaling group. To bind multiple Server Load Balancer instances, you can submit a ticket to apply for a higher quota and our staff will help you within one business day (our response may be postponed on weekends and during holiday periods).

When Auto Scaling creates an ECS instance, can the instance be added to multiple Server Load Balancer instances?

Yes. At present, an ECS instance can only be added to one Server Load Balancer instance, but you can submit a ticket to apply to have it bound to multiple Server Load Balancer instances.

Can I modify the weights of ECS instances added to an Auto Scaling group Server Load Balancer instance?

Currently, the ECS instances under Auto Scaling Sever Load Balancer instances have a weight of 50 by default. This should be appropriate, as the backend ECS instances of Auto Scaling groups normally carry the same services and are the same type. Also, the Server Load Balancer distributes traffic based on the weight ratio, not the actual number. Thus, if you have two backend ECS instances weighted 50 and 50 (with a ratio of 1:1), this is the same as they are weighted 100 and 100 (the ratio is also 1:1).

I already have a public network Server Load Balancer instance. If I create a scaling configuration, will its ECS instances need public bandwidth?

When you create a scaling configuration, you do not have to allocate public bandwidth to its ECS instances. However, we suggest you buy at least 1 Mbps of ECS bandwidth, as this will make it easier for you to manage ECS instances.

Do I have to use SLB, CloudMonitor, and RDS together with Auto Scaling?

Auto Scaling is an open elastic scaling platform. Auto Scaling can independently scale up or down ECS instances. It can be deployed either separately or with Server Load Balancer and RDS. Auto Scaling allows CloudMonitor to trigger ECS instance scaling up or down actions. Or, you can use Auto Scaling's API to connect to your own monitoring system to trigger scaling actions.

Scaling configuration and rule

What information should I provide for Auto Scaling problems?

You can provide your auto scaling activity ID or the relevant logs to facilitate our troubleshooting process.

When creating a scaling configuration for Auto Scaling, why can't I select ECS instances I have already bought?

Auto Scaling allows you to add existing ECS instances under the following conditions:

  • The ECS instance you want to add and the scaling group must be in the same region.

  • The ECS instance you want to add and the instance in the scaling configuration must be the same type.

  • The ECS instance you want to add must be in "Running" status and cannot be found in another scaling group. The ECS instance you want to add cannot be a VPC.

  • The ECS instance you want to add can be a Subscription or Pay-As-You-Go instance. When removed from the scaling group, the ECS instance will not be released.

Can I add existing subscription instances to Auto Scaling?

Currently, Auto Scaling automatically creates Pay-As-You-Go instances by default, but you can also add your existing Monthly Subscription or Pay-As-You-Go instances.

Can I add a single ECS instance to different scaling groups?

At present, this is not allowed.

Can I add ECS instances with different rules to Auto Scaling groups?

You can only set one scaling configuration type (CPU or Memory) for each Auto Scaling group. However, you can set different configurations for each of the multiple scaling groups.

In the Auto Scaling service, each scaling group can have up to 100 instances. Can I increase the maximum number of instances?

You can submit a ticket to apply for a higher quota and our staff will help you within one business day (our response may be postponed on weekends and holidays).

In the Auto Scaling service, can the ECS instances in scaling groups have 8-core and 16-core configurations?

Yes, to use high-configuration ECS instances, go to the ECS Pay-As-You-Go page and submit "Request Higher Configuration". Our staff will help you within one business day, but our response may be postponed on weekends and holidays.

When I remove an ECS instance from a scaling group and release the instance, can I save the ECS instance data?

  • When you remove an ECS instance and then release it, you will be unable to retain the data.

  • Because Auto Scaling will automatically release ECS instances, Auto Scaling ECS instances cannot be used to save application status information (ie. session information) or related data (ie. databases and logs). Status information can be saved to an independent state server, database (ie. RDS), shared cache (ie. OCS), or centralized log storage (ie. SLS).

If I use the API to call the DisableScalingGroup method, will this release the automatically added ECS instances?

When you execute DisableScalingGroup, the Pay-As-You-Go instances created by Auto Scaling will not be automatically released.

Will ECS instances automatically added into a scaling group be automatically included into the RDS and OCS IP address white lists?

Auto Scaling supports RDS access white lists. When ECS instances are added or removed, the instance IP addresses will be automatically added to or removed from the RDS access white list. However, OCS white lists are not supported at present.

Do ECS instances added to scaling groups support vertical scaling, CPU and memory upgrades?

Auto Scaling currently does not support vertical scaling. That is, it cannot automatically upgrade/downgrade an ECS instance's CPU, memory, or bandwidth.

Does Auto Scaling support periodic task repetition, to repeat tasks within a specified time period?

On the Auto Scaling console, go to Auto-trigger Task Management > Scheduled Tasks to set scheduled tasks. If you do not set a repetition period, the task is only executed on the specified date and time. Otherwise, the designated execution time defaults to be the time point executing this task periodically. If you do not set a repetition period for it, the scheduled task will not be terminated.

How can I ensure that manually added ECS instances are not removed from the scaling group?

If you need to add 'x' number of subscription ECS instances to the scaling group and do not want these instances to be automatically removed, you must set both of the configurations below:

  • Set the minimum number of instances (MinSize) to 'x' or greater.

  • Set the Removal Policy's first selection rule to "Oldest Scaling Configuration."

Based on the Auto Scaling rules, manually added ECS instances will not match any scaling configuration (because they were not created by a scaling configuration). Therefore, Auto Scaling will remove the automatically created ECS instances from the scaling group. Manually added ECS instances will be removed only after all the automatically created ECS instances have been removed.

Please note that automatically created ECS instances will be automatically released when they are removed from a scaling group. Manually created and added ECS instances will not be released if they are removed from a scaling group.

Note: The above is the logic for healthy instances. If you stop a manually added ECS instance, Auto Scaling will view it as "unhealthy" and remove it. This is because Auto Scaling must ensure that the ECS instances in the scaling group are "healthy".

Monitoring and automation

How does Auto Scaling judge if its ECS instances are available?

If available in an Auto Scaling group, the Server Load Balancer will check that the ports of your backend ECS instance are functional before forwarding requests to the ESC instance.

What are the triggering conditions for Auto Scaling alarms?

Monitoring alarms are triggered based on the CPU load, memory usage, average system load, Internet and intranet inbound and outbound traffic, and other indicators, to automatically increase or decrease the number of ECS instances.

Can Auto Scaling support dynamic scaling based on the custom alarms in CloudMonitor?

At present, dynamic scaling is not supported based on custom monitoring settings.