This topic describes how to adjust the scaling range for your serverless ApsaraDB RDS for PostgreSQL instance. You can modify the range to ensure sufficient resources for peak workloads or to reduce costs during periods of low activity.
Background
The performance of a serverless ApsaraDB RDS for PostgreSQL instance is measured in RDS Capacity Units (RCUs). The instance automatically scales the number of RCUs up or down based on your workload, staying within the minimum and maximum capacity that you set.
If the Database Capacity (RCUs per Second) metric on the Basic Information page reaches its configured maximum during peak hours but is still insufficient for your business needs, you can manually increase the maximum RCU value.
Usage notes
This feature is available only if your ApsaraDB RDS for PostgreSQL instance uses the Serverless billing method.
Limitations
If the maximum value for RCUs is already set to 14, you cannot increase it further.
If you need more compute resources, change the billing method to pay-as-you-go and upgrade to a different ApsaraDB RDS for PostgreSQL instance type series. For more information, see Primary ApsaraDB RDS for PostgreSQL instance types.
Impacts
RCU scaling for a serverless instance takes effect immediately and does not impact your services.
Billing
You are not charged for changing the RCU scaling range. RCU fees are based only on actual usage. For more information, see Overview of serverless ApsaraDB RDS for PostgreSQL instances.
Procedure
Go to the Instances page. In the upper-left corner, select the region of your instance, and then click the instance ID.
In the Configuration Information section, click Modify Scaling Settings.
In the dialog box that appears, set the Minimum and Maximum values for RDS Capacity Units (RCUs).
NoteThe value can range from 0.5 to 14 RCUs. You can set the values based on your business requirements.
Click OK.
FAQ
Q: The maximum RCU capacity for my instance is 14, but it is still not enough for my workload. What should I do?
A: We recommend that you change the billing method to pay-as-you-go and upgrade to a different ApsaraDB RDS for PostgreSQL instance type series. For example, an instance on the High-availability Edition that uses a dedicated instance type can support up to 104 cores and 768 GB of memory. To change the billing method, see Change a Serverless instance to pay-as-you-go. For more information about instance types, see Primary ApsaraDB RDS for PostgreSQL instance types.
References
To save costs by automatically pausing your serverless ApsaraDB RDS for PostgreSQL instance when it has no connections, see Configure the automatic start and stop feature.
You can change the scaling policy to balance performance and availability. You can use the default Do Not Execute Forcefully policy to avoid potential service interruptions, or use the Execute Forcefully policy when performance matters more than continuous availability. For more information, see Change the scaling policy of RCUs.
RCU scaling is typically completed in seconds. In rare cases, it might take 3 to 5 minutes due to cross-instance scaling. If you have strict stability requirements for specific periods, you can configure a scheduled task to increase the number of RCUs for your serverless instance in advance. For more information, see Configure scheduled tasks to adjust the number of RCUs for a serverless RDS instance.
You can call the ModifyDBInstanceSpec operation to modify the RCU range of a serverless ApsaraDB RDS for PostgreSQL instance. The following table describes the required parameters:
Parameter
Description
Example
DBInstanceId
The ID of the serverless instance to modify.
pgm-****
PayType
The billing method of the serverless instance. Set the value to Serverless.
Serverless
Direction
The type of specification change for the instance. Set the value to Serverless.
Serverless
ServerlessConfiguration.MaxCapacity
The maximum value in the automatic scaling range for RCUs.
14
ServerlessConfiguration.MinCapacity
The minimum value in the automatic scaling range for RCUs.
0.5