The capabilities of an ApsaraDB RDS for SQL Server instance vary with the instance's major engine version (SQL Server version) and RDS edition. For better performance and scalability, you can upgrade your instance to a higher version and edition. For example, you can upgrade the major version of an instance from SQL Server 2019 Standard Edition to SQL Server 2022 Standard Edition, or upgrade the instance edition from Basic Edition to High-availability Edition.
Background information
RDS for SQL Server offers instances in three editions, each with different features and advantages.
Basic Edition instances do not have a secondary instance for hot standby. This may cause extended downtime if an instance fails or during tasks like specification changes or version upgrades.
High-availability Edition instances use a classic high-availability architecture with a primary instance and a secondary instance. Data from the primary instance is synchronized to the secondary instance semi-synchronously or asynchronously. If the primary instance fails, the system automatically fails over to the secondary instance.
Cluster Edition instances are based on the Always On technology of SQL Server, which decouples compute from storage. This edition lets you create one or more read-only instances to implement read/write splitting, ideal for high read volumes.
Usage notes
Upgrades of the major engine version, edition, and instance type are irreversible. The upgrade rules are as follows:
WarningBecause upgrades are irreversible, we recommend that you first create a pay-as-you-go or serverless target instance to test compatibility.
During the upgrade, do not modify instance metadata. This can cause data inconsistencies after the upgrade. Metadata modification operations include, but are not limited to, adding or deleting databases, or changing the recovery model of a database.
The upgrade will involve a cross-host migration, which will clear the host account and any programs or files, such as SSIS, SSAS, and SSRS, on the original host. You must migrate or back up your data in advance.
ImportantIn most cases, minor engine version updates do not cause compatibility issues. However, they may cause changes in functionality. We recommend that you check the SQL Server cumulative updates (CUs) released by Microsoft to verify whether the SQL Server kernel is updated.
Limitations
The following instances do not support database version upgrades:
Instances joined to an Active Directory (AD) domain.
Serverless instances.
Read-only instances and Cluster Edition primary instances that have read-only instances attached.
Cluster Edition primary instances with the read-only endpoint for the secondary instance enabled.
Impacts
Once started, the upgrade process cannot be canceled, and it cannot be rolled back after completion.
Your existing settings, such as the instance name, port, tags, and database accounts, remain unchanged after the upgrade.
The upgrade duration depends on factors such as the data volume of your instance. For more information, see the FAQ section in this topic.
The upgrade involves a network switchover, which causes a service interruption that can last up to 20 minutes. For more information, see the FAQ section in this topic. Ensure that your application has an automatic reconnection mechanism.
During the upgrade, the process migrates the instance's underlying resources, which causes the virtual IP (VIP) address to change. To ensure business stability and continuity, you must use the internal or public endpoint of the RDS instance to connect to your application. Do not use the resolved IP address. The RDS endpoint is a dynamic domain name with automatic routing capabilities that seamlessly adapts to backend IP changes.
If you choose to switch within the maintenance window, regular instance backups are disabled from when you submit the upgrade task until the migration is complete.
Clear the DNS cache on your client. If your client is a JVM-based application, we recommend setting the TTL in the JVM configuration to 60 seconds or less. This ensures that when the VIP address of the endpoint changes, the application can obtain the new VIP address by re-querying the DNS.
NoteThe following methods for setting the TTL in the JVM are for your reference:
To set the TTL for all JVM-based applications, set the networkaddress.cache.ttl parameter in the $JAVA_HOME/jre/lib/security/java.security file to 60.
To set the TTL for only a local application, set
java.security.Security.setProperty("networkaddress.cache.ttl" , "60");in the application's initialization code before any network connections are established, specifically before the first call toInetAddress.getByName().
If you have an ongoing Data Transmission Service (DTS) task, you must reconfigure and restart the task after the upgrade.
Billing
For information about the fees for upgrading the version, see change specifications.
Procedure
Go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the ID of the instance.
On the Basic Information page, in the Configuration Information section, click Upgrade Version. In the dialog box that appears, click OK.
NoteIf Upgrade Version is not displayed, check whether your instance meets the upgrade requirements.
On the Upgrade Engine Version page, modify the configuration. The following table describes the key parameters. For information about other parameters, see Procedure.
NoteSome instances may have restrictions on the available versions and editions during an upgrade. For more information, see the Usage notes and Limitations sections in this topic.
Parameter
Description
Upgrade To
The available options for Edition and Instance Type change based on the target version you select. For more information, see Upgrade rules.
Edition
Select the target edition:
Basic Edition: A single-node architecture with compute and storage decoupled.
High-availability Edition: A classic high-availability architecture with a primary and a secondary instance, providing balanced performance.
Cluster Edition: A high-availability architecture with one primary and multiple secondary instances. The secondary instances are accessible for read operations.
Instance Type
Each instance type has a specific vCPU count, memory size, maximum number of connections, and maximum IOPS.
Switching Time
Switch Immediately After Data Migration: The migration and switchover start immediately.
Switch Within Maintenance Window: The migration starts immediately, and the switchover occurs during the configured maintenance window.
Click Pay Now. In the dialog box that appears, click OK.
The status of the instance changes to . When the status of the instance changes to Running, the upgrade is complete. The time required depends on the amount of data. Please wait patiently.
FAQ
Related API
You can also upgrade the major database version by calling an API. For more information, see Modify an RDS instance.