Help Center/ Distributed Cache Service/ FAQs/ Data Backup, Export, and Migration/ How Do I Export DCS Redis Instance Data?
Updated on 2022-09-15 GMT+08:00

How Do I Export DCS Redis Instance Data?

  • Master/standby and cluster instances:
    These instances support backups. Perform the following operations to export data:
    1. On the Backups and Restorations page, view the backup tasks.
    2. If there is no backup, create a backup and download the backup file as prompted.
  • Single-node instances:

    Single-node instances do not support the backup function. You can use redis-cli to export data to RDB files. This operation depends on SYNC command.

    • If the instance allows the SYNC command, run the following command to export the instance data:

      redis-cli -h {source_redis_address} -p 6379 [-a password] --rdb {output.rdb}

    • If the instance does not allow the SYNC command (such as a Redis 4.0 or 5.0 single-node instance), migrate the instance data to a master/standby instance and export the data by using the backup function.