To use the features of a later version, upgrade your ApsaraDB for Redis instance to a major version in the ApsaraDB for Redis console. For example, you can upgrade the major version from Redis 2.8 to Redis 4.0.

Procedure

The upgrade procedure varies based on the architecture. For more information, see the following table.

Architecture Procedure
Cluster instances
  1. Apply for resources that are required for creating an instance of a new version, such as proxy node resources.
  2. Synchronize the full and incremental data from the original instance to an instance of the new version.
  3. Switch instances. When data synchronization is close to completion, the original instance is set to the read-only state within 60 seconds until all data is synchronized. After data synchronization is completed, the system disassociates the virtual IP address (VIP) from the original instance and associates the VIP with the new instance.
    Note If you select Update During Maintenance, the system performs the switchover operation within the maintenance window of the instance.
  4. Complete the upgrade. Release the resources of the original instance and change the the new instance to the Running state.
Read/write splitting instances
Standard instances
  1. Upgrade the replica node. Stop the original replica node and then start a replica node of a later version.
  2. Synchronize data from the master node to a replica node of a later version.
  3. Switch from the master node to the replica node. When data synchronization is close to completion, the instance is set to the read-only state within 60 seconds until all data is synchronized. After data synchronization is completed, the system disassociates the VIP from the master node and associates the VIP to the replica node. Meanwhile, the system switches the master and replica nodes to promote the replica node of a later version to the master node.
    Note If you select Update During Maintenance, the system switches the master and replica nodes within the maintenance window of the instance.
  4. Upgrade the master node that is demoted to replica node. The original master node becomes a replica node. The system repeats Step 1 and Step 2 to upgrade the replica node and synchronize data.
  5. Complete the upgrade. The instance is changed to the Running state.

Impacts

  • The Redis service remains unaffected during the phases of applying for resources, upgrading replica nodes, and synchronizing data.
  • During the instance switchover or master/replica switchover, the instance experiences transient connections for a few seconds. The instance stays in the read-only state within 60 seconds until all data is synchronized. Upgrade the instance during off-peak hours and make sure that your application is configured with a reconnection mechanism.
  • When you upgrade the major version of an instance of ApsaraDB for Redis 4.0, Bloom filter-related API operations, such as BF.ADD, are no longer supported.
    Notice Bloom filter-related API operations on existing instances of ApsaraDB for Redis 4.0 are only for internal use. In addition, newly purchased instances of ApsaraDB for Redis 4.0 and major versions later than 4.0 no longer support Bloom filter-related API operations. Therefore, if you call Bloom filter-related API operations, you will fail to perform cache analytics and unknown errors may occur. We recommend that you change the instance to ApsaraDB for Redis Enhanced Edition (Tair) (Performance-enhanced instances) that supports the optimized Bloom filter.

Procedure

  1. Log on to the ApsaraDB for Redis console.
  2. In the top navigation bar of the page, select the region where the instance is deployed.
  3. On the Instances page, click the ID of the instance.
  4. In the Basic Information section, click Major Update.
    Figure 1. Upgrade the major version
    Upgrade the major version of an ApsaraDB for Redis instance
    Note If the Major Update button does not appear, you are using the latest major version.
  5. In the panel that appears on the right side of the page, select the major version to which you want to upgrade and the scheduled time to upgrade.
    Notice When instances or the master and replica nodes are switched over, the instance experiences transient connections for a few seconds and stays in the read-only state within 60 seconds. We recommend that you select Update During Maintenance. This way, the system switches the instances or master and replica nodes within the maintenance window of the instance to minimize the impact. For more information about how to specify a maintenance window, see Specify a maintenance window.
  6. Click OK.

Related operations

API Description
ModifyInstanceMajorVersion Upgrades the major version of an ApsaraDB for Redis instance.

FAQ

Q: Why does an instance changes to the Upgrading Major Version state after I select Update During Maintenance to upgrade the major version?

A: The system is preparing for upgrades. The preparation process includes operations such as applying for resources and synchronizing data. During this process, instances or master and replica nodes are not switched over and your services are not affected.
Note The instance experiences transient connections for a few seconds and stays in the read-only state within 60 seconds only when the system switches the instances or master and replica nodes.