Based on Data Transmission Service (DTS) and redis-shake tools, ApsaraDB for Redis provides multiple data migration solutions. This allows you to migrate data in different scenarios based on your business requirements.

Data migration tools

  • DTS (Recommended)

    DTS is a real-time data streaming service that is provided by Alibaba Cloud. The service allows you to migrate, subscribe to, and synchronize data by using stable and secure transmission channels. DTS supports full data migration and incremental data migration with minimized downtime. This ensures service availability.

  • redis-shake

    Redis-shake is an open source Linux-based tool that is developed by Alibaba Cloud. You can use this flexible and efficient tool to parse (decode mode), restore (restore mode), back up (dump mode), and synchronize (sync or rump mode) data on ApsaraDB for Redis instances. If DTS is unavailable, you can use redis-shake to migrate data.

The following table describes the differences between DTS and redis-shake for Redis data migration:

Note
  • You can use different databases and architectures that are listed in the following table in data migration. For example, you can use DTS to migrate data from a user-created Redis database to an ApsaraDB for Redis instance.
  • The data synchronization feature of DTS has many benefits for data synchronization. We recommend that you use the data synchronization feature of DTS to migrate data. For more information, see Overview.
Table 1. Supports for data migration
Tool Supported source database Supported destination database Supported architecture Supported migration type
DTS (Recommended)

User-created Redis database

Version 2.8, 3.0, 3.2, 4.0, and 5.0

  • User-created Redis database

    Version 2.8, 3.0, 3.2, 4.0, and 5.0

  • ApsaraDB for Redis Community Edition

    Version 4.0 and 5.0

  • ApsaraDB for Redis Enhanced Edition (Tair)

    Version 5.0

  • Full data migration
  • Incremental data migration
redis-shake
  • User-created Redis database

    Version 2.8, 3.0, 3.2, 4.0, and 5.0

  • ApsaraDB for Redis Community Edition

    Version 4.0 and 5.0

  • User-created Redis database

    Version 2.8, 3.0, 3.2, 4.0, and 5.0

  • ApsaraDB for Redis Community Edition

    Version 4.0 and 5.0

  • ApsaraDB for Redis Enhanced Edition (Tair)

    Version 5.0

The source and destination databases support the following architectures:
  • Full data migration
  • Incremental data migration

Required permissions

The permissions that are required by DTS and redis-shake vary based on different migration scenarios. Before you perform data migration, grant the required permissions to the source database and destination database based on the scenarios that are described in the following table.

Note For more information about how to create an account for an ApsaraDB for Redis instance and grant the required permissions to the account, see Create and manage database accounts.
Tool Scenario Permission on the source database Permission on the destination database
DTS (Recommended)
  • Migrate data from user-created Redis to ApsaraDB for Redis
  • Migrate data between user-created databases
Permissions to run the SYNC or PSYNC command. Read and write permissions
redis-shake
  • Migrate data from user-created Redis to ApsaraDB for Redis
  • Migrate data between user-created databases
Permissions to run the SYNC or PSYNC command. Read and write permissions
  • Migrate data between instances of the same Alibaba Cloud account
  • Migrate data across Alibaba Cloud accounts
  • Migrate data from ApsaraDB for Redis to user-created Redis
Replication permissions
Note If the source database is a cluster instance or read/write splitting instance, you cannot create an account that is granted the replication permissions.To enable this feature, submit a ticket.
Read and write permissions

Data migration solutions

Table 2. Migration solutions
Scenario Tool Solution
Migrate data from user-created Redis to ApsaraDB for Redis DTS Migrate data from a self-managed Redis database to an ApsaraDB for Redis instance
Synchronize data from a Codis cluster hosted on ECS to an ApsaraDB for Redis instance
Note This solution uses the data synchronization feature of DTS to migrate data.
Synchronize data from Twemproxy Redis on ECS to ApsaraDB for Redis
Note This solution uses the data synchronization feature of DTS to migrate data.
redis-shake Use redis-shake to migrate data
Use redis-shake to migrate data from on-premises Codis or Redis to ApsaraDB for Redis
Use redis-shake to migrate data from an RDB file
Use AOF files to migrate data
Migrate data between ApsaraDB for Redis instances redis-shake Use redis-shake to migrate data
Migrate data from a third-party database to ApsaraDB for Redis redis-shake Migrate data from Amazon ElastiCache for Redis to ApsaraDB for Redis
Migrate data from SSDB to ApsaraDB for Redis
Migrate data from Google Cloud Memorystore for Redis to ApsaraDB for Redis