All Products
Search
Document Center

ApsaraDB RDS:Upgrade the minor engine version of an ApsaraDB RDS for PostgreSQL instance

Last Updated:Jun 21, 2026

ApsaraDB RDS for PostgreSQL lets you upgrade the minor engine version. These upgrades provide performance improvements, new features, and security fixes to continuously optimize and secure your database service.

For more information about the features of the ApsaraDB RDS for PostgreSQL minor engine versions, see AliPG kernel minor version releases (PostgreSQL 14 to 18).

Usage notes

  • Upgrading the minor engine version restarts the instance, which causes a connection interruption of about 30 seconds. We recommend performing the upgrade during off-peak hours or ensuring that your application has an automatic reconnection mechanism.

  • You cannot downgrade the minor engine version after an upgrade.

  • Minor engine version upgrades typically do not cause compatibility issues. However, extension upgrades might. If the upgrade involves an extension, such as the GanosBase extension, we recommend using the Restore PostgreSQL data feature to create a test instance and verify the new extension's compatibility.

  • Keep the following points in mind for extension upgrades:

    • If your instance uses the PostGIS or GanosBase extension, you must also manually upgrade the PostGIS or GanosBase extension after upgrading the minor engine version. For more information, see Upgrade spatiotemporal engine extensions.

    • If your instance runs PostgreSQL 14 with a minor engine version earlier than 20230330 and you use the TimescaleDB extension (version 2.5.0 or earlier), you must upgrade the extension after upgrading the minor engine version to 20230330 or a later version. To do so, manually run the ALTER EXTENSION timescaledb UPDATE; command. This step is necessary to continue using the TimescaleDB extension.

View the minor engine version

You can view an instance's current minor engine version in one of the following ways:

  • Log on to the ApsaraDB RDS console. The version is available on the Basic Information page of your instance.

    Note

    This method applies only to ApsaraDB RDS for PostgreSQL cloud disk instances.

  • Connect to the target PostgreSQL instance and run the show rds_release_date; command.

    Note

    This method applies to ApsaraDB RDS for PostgreSQL cloud disk instances and local disk instances.

Manually upgrade the minor engine version

Upgrade local disk instances

You cannot manually upgrade a local disk instance. To upgrade, restart the instance to automatically update it to the latest minor engine version. For more information, see Restart an ApsaraDB RDS for PostgreSQL instance.

Note

For primary instances with attached read-only instances, first restart each read-only instance, and then restart the primary instance. Restarting only the primary instance does not upgrade the minor engine versions of the attached read-only instances.

Upgrade cloud disk instances

Note

For a primary instance with attached read-only instances, you can use one of the following upgrade methods:

  • Start the upgrade on the primary instance. This action first upgrades all attached read-only instances concurrently, and then upgrades the primary instance.

  • To avoid a simultaneous upgrade of all read-only instances, upgrade each one individually before you upgrade the primary instance.

  1. 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.

  2. In the Configuration Information section, click Update Minor Engine Version.

  3. In the dialog box that appears, select a version from the Latest Version drop-down list, specify the Update Time, and then click OK.

    The Latest Version string consists of the following parts:

    • rds: The instance is an RDS instance.

    • postgres: The database engine is PostgreSQL.

    • 1200: The PostgreSQL major version is 12.

    • 20220830: The minor engine version of the AliPG kernel. For more information about each minor engine version, see AliPG kernel minor version releases (PostgreSQL 14 to 18).

    • 12.11: The PostgreSQL community minor version.

Automatically upgrade the minor engine version

Warning

Automatic upgrades are a supplementary method and do not guarantee that all instances are immediately upgraded to the latest minor engine version. You can view the status of the minor engine version on the Basic Information page of your instance and proactively upgrade the minor engine version to mitigate potential risks that are associated with outdated versions. If you cancel a system-initiated upgrade task or fail to upgrade to the latest stable version after you receive a notification in the console, you are liable for any resulting business interruptions or data loss. For more information, see the Terms of Service.

When you purchase an ApsaraDB RDS for PostgreSQL instance with cloud disks, the Minor Engine Version Update Policy is set to Automatic Upgrade by default. If your minor engine version is earlier than the latest version, the system periodically schedules proactive O&M tasks to upgrade the minor engine version. You are notified of these tasks by email, and internal messages. The automatic upgrade is performed within the maintenance window that you configure. You can change the upgrade time in Event Management or cancel a task before it starts. For more information, see Scheduled events.

Note

The automatic minor engine version upgrade feature is available only for cloud disk instances.

Modify automatic upgrade settings

  1. 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.

  2. On the Basic Information page, go to the Configuration Information section and view the status of Automated Update of Minor Engine Version.

  3. Click Settings to the right of Automated Update of Minor Engine Version.

  4. In the dialog box that appears, select Automatic Upgrade or Manual Upgrade and click OK.

FAQ

What should I do if accessing the PostGIS or GanosBase extension fails after a minor engine version upgrade?

After you upgrade the minor engine version, you must also manually upgrade the PostGIS or GanosBase extension. For more information, see Upgrade spatiotemporal engine extensions.

What PostGIS compatibility issues might occur during a minor engine version upgrade?

The following table describes the compatibility differences.

Note

The following compatibility issues may occur on ApsaraDB RDS for PostgreSQL instances running a minor engine version earlier than 20211031.

PostGIS extension version

Engine upgrade only

Engine and extension upgrade

2.5.x

  • The following functions may cause the database to crash:

    • ST_ClusterKMeans

    • ST_GeomFromKML

    • ST_AsKML

  • The following functions report an error:

    • ST_Buffer

      Error message: Invalid buffer parameter: uad_segs (accept: 'endcap', 'join', 'mitre_limit', 'miter_limit', 'quad_segs' and 'side')

      Solution: Change the quadsegs parameter to quad_segs.

    • ST_Intersects

      Error message: ERROR: GetGenericCacheCollection: Could not find upper context

      Solution: None.

  • The following functions are removed and can no longer be used:

    • ST_Force_2D

    • ST_Locate_Along_Measure

    • ST_Estimated_Extent

  • The parameter values or syntax for the following functions change after the upgrade:

    • ST_GeomFromGeoJSON: After the upgrade, SRID=4326 is specified by default.

    • ST_AsGeoJSON: The maxdecimaldigits parameter is changed from 16 to 9.

    • The syntax for MultiPoint changes:

      • Before the upgrade: MULTIPOINT(1 1,-1 1)

      • After the upgrade: MULTIPOINT((1 1),(-1 1))

  • The following functions are removed and can no longer be used:

    • ST_Force_2D

    • ST_Locate_Along_Measure

    • ST_Estimated_Extent

  • The parameter values or syntax for the following functions change after the upgrade:

    • ST_GeomFromGeoJSON: After the upgrade, SRID=4326 is specified by default.

    • ST_AsGeoJSON: The maxdecimaldigits parameter is changed from 16 to 9.

    • The syntax for MultiPoint changes:

      • Before the upgrade: MULTIPOINT(1 1,-1 1)

      • After the upgrade: MULTIPOINT((1 1),(-1 1))

3.1.x

  • The following function may cause the database to crash:

    • ST_ClusterKMeans

  • The syntax for MultiPoint changes:

    • Before the upgrade: MULTIPOINT(1 1,-1 1)

    • After the upgrade: MULTIPOINT((1 1),(-1 1))

The syntax for MultiPoint changes:

  • Before the upgrade: MULTIPOINT(1 1,-1 1)

  • After the upgrade: MULTIPOINT((1 1),(-1 1))

Related documents