All Products
Search
Document Center

Data Transmission Service:Configure one-way data synchronization between Tair (Redis OSS-Compatible) instances across Alibaba Cloud accounts

Last Updated:Mar 28, 2026

Use Data Transmission Service (DTS) to synchronize data from a Tair (Redis OSS-Compatible) instance under one Alibaba Cloud account to an instance under a different account. This setup supports resource migration across accounts and business architecture adjustments.

The process involves two accounts:

  • Account A — owns the source instance. Grants cross-account access via a RAM role.

  • Account B — owns the destination instance. Configures and runs the DTS synchronization task.

Prerequisites

Before you begin, make sure that you have:

  • A destination Tair (Redis OSS-Compatible) instance with available storage larger than the total data size in the source instance

  • Verified that your source and destination instance versions are compatible. See Overview of data synchronization scenarios for supported versions.

Limits

Compatibility constraints (check before you configure)

Review these constraints before starting. If any apply to your setup, resolve them first.

ConstraintDetail
TDEIf transparent data encryption (TDE) is enabled on either instance, DTS cannot synchronize data.
SSL/TLSSSL-encrypted connections do not support TLSv1.3. Tair instances with SSL enabled cannot connect to DTS as an Alibaba Cloud Instance.
Source versionSynchronize from a lower or equal version to a higher version. Synchronizing from a higher to a lower version may cause compatibility issues.
Cluster cross-slot operationsIf the source is a Basic Edition instance and the destination is a cluster instance, operations on keys spanning multiple slots cause a CROSSSLOT Keys in request don't hash to the same slot error. During synchronization, operate on one key at a time.
Persistent memory (Tair Enterprise Edition)If the source uses Persistent Memory storage, set the appendonly parameter to yes before starting. See Disable AOF persistence.
Memory eviction policyBy default, Tair (Redis OSS-Compatible) instances use the volatile-lru eviction policy. If the destination runs low on memory, data eviction can cause inconsistency without stopping the task. Set maxmemory-policy to noeviction on the destination to make the task fail explicitly instead of silently losing data. See What is the default eviction policy of Tair?
Destination storageIf a shard's memory reaches its limit, or the destination has insufficient storage, the task fails with an out of memory (OOM) error.
Other writes to the destinationWriting data from other sources to the destination during synchronization causes data inconsistency.

Runtime behaviors

These behaviors apply while the task is running.

BehaviorDetail
Heartbeat keyDTS inserts a key prefixed DTS_REDIS_TIMESTAMP_HEARTBEAT into the source database to track update timestamps. For cluster instances, DTS inserts this key into each shard. The key is filtered during synchronization and expires when the task ends.
Latency reportingIf the source is read-only or the DTS account lacks SETEX permission, reported synchronization latency may be inaccurate.
repl-backlog-sizeIncrease the repl-backlog-size value in redis.conf to improve synchronization stability.
Key expirationKeys with an expiration policy may not be deleted immediately after they expire. As a result, the destination may have fewer keys than the source. Run the info command to view the number of keys in the destination database.
Self-managed Redis: replication timeoutFor self-managed Redis sources, run config set repl-timeout 600 to set a 600-second replication timeout. Increase this value if the source has a large dataset.
Self-managed Redis: connection address changesIf the connection address of a self-managed source or destination changes during synchronization, reconfigure the task.
Shard count or spec changesIf the source shard count changes, or if you change the database specifications (such as scaling up memory capacity), reconfigure the task. Clear already-synchronized data in the destination before reconfiguring to maintain consistency.
Restarting a synchronization instanceRestarting the instance may cause DTS to re-run both the full and incremental synchronization phases.
Full resynchronization triggersAny of the following causes DTS to resynchronize all data to the destination, which may result in temporary inconsistency: a transient connection failure (breakpoint resume fails), a primary-replica switch or failover, a connection address change, or a modification to the synchronization objects.
LIST data (SYNC/PSYNC)DTS does not clear existing LIST data in the destination when transferring via SYNC or PSYNC. The destination may contain duplicate records.
Task failure recoveryIf a task fails, DTS technical support attempts to restore it within 8 hours. During recovery, the task may be restarted and task parameters (not database parameters) may be modified.

Billing

Synchronization typeFee
Schema synchronization and full data synchronizationFree
Incremental data synchronizationCharged. See Billing overview.

Commands supported for incremental synchronization

Tair (Redis OSS-Compatible) Open-Source Edition

APPEND, BITOP, BLPOP, BRPOP, BRPOPLPUSH, DECR, DECRBY, DEL, EVAL, EVALSHA, EXEC, EXPIRE, EXPIREAT, GEOADD, GETSET, HDEL, HINCRBY, HINCRBYFLOAT, HMSET, HSET, HSETNX, INCR, INCRBY, INCRBYFLOAT, LINSERT, LPOP, LPUSH, LPUSHX, LREM, LSET, LTRIM, MOVE, MSET, MSETNX, MULTI, PERSIST, PEXPIRE, PEXPIREAT, PFADD, PFMERGE, PSETEX, RENAME, RENAMENX, RESTORE, RPOP, RPOPLPUSH, RPUSH, RPUSHX, SADD, SDIFFSTORE, SELECT, SET, SETBIT, SETEX, SETNX, SETRANGE, SINTERSTORE, SMOVE, SPOP, SREM, SUNIONSTORE, SWAPDB, UNLINK (SWAPDB and UNLINK can be synchronized only if the engine version of the source database is Redis 4.0), XADD, XCLAIM, XDEL, XAUTOCLAIM, XGROUP CREATECONSUMER, XTRIM, ZADD, ZINCRBY, ZINTERSTORE, ZREM, ZREMRANGEBYLEX, ZREMRANGEBYRANK, ZREMRANGEBYSCORE, ZUNIONSTORE

Tair (Redis OSS-Compatible) Enterprise Edition

APPEND, BITOP, BLPOP, BRPOP, BRPOPLPUSH, DECR, DECRBY, DEL, EVAL, EVALSHA, EXEC, EXPIRE, EXPIREAT, GEOADD, GETSET, HDEL, HINCRBY, HINCRBYFLOAT, HMSET, HSET, HSETNX, INCR, INCRBY, INCRBYFLOAT, LINSERT, LPOP, LPUSH, LPUSHX, LREM, LSET, LTRIM, MOVE, MSET, MSETNX, MULTI, PERSIST, PEXPIRE, PEXPIREAT, PFADD, PFMERGE, PSETEX, RENAME, RENAMENX, RPOP, RPOPLPUSH, RPUSH, RPUSHX, SADD, SDIFFSTORE, SELECT, SET, SETBIT, SETEX, SETNX, SETRANGE, SINTERSTORE, SMOVE, SPOP, SREM, SUNIONSTORE, UNLINK, XADD, XCLAIM, XDEL, XAUTOCLAIM, XGROUP CREATECONSUMER, XTRIM, ZADD, ZINCRBY, ZINTERSTORE, ZREM, ZREMRANGEBYLEX, ZREMRANGEBYRANK, ZREMRANGEBYSCORE, ZUNIONSTORE

Unsupported commands and caveats

  • PUBLISH is not supported.

  • For EVAL and EVALSHA: DTS cannot confirm whether Lua scripts executed on the source also execute successfully on the destination, because the destination does not return explicit results during incremental synchronization.

  • For SYNC and PSYNC on LIST data: DTS does not clear existing data in the destination before writing, so the destination may contain duplicate records.

Step 1: Grant cross-account access (Account A)

Log in to the Alibaba Cloud Management console with Account A (the account that owns the source Tair instance). Create a RAM role, set Account B as the trusted account, and authorize the RAM role to access Account A's cloud resources.

For detailed steps, see Configure RAM authorization for cross-account DTS tasks.

Step 2: Configure the synchronization task (Account B)

Log in with Account B (the account that owns the destination Tair instance) and complete the following steps.

Go to the Data Synchronization Tasks page

DTS console

  1. Log on to the DTS console.

  2. In the navigation pane on the left, click Data Synchronization.

  3. In the upper-left corner of the page, select the region where the synchronization instance is located.

DMS console

Note

The actual steps may vary depending on the mode and layout of the DMS console. For more information, see Simple mode console and Customize the layout and style of the DMS console.

  1. Log on to the DMS console.

  2. In the top menu bar, choose Data + AI > DTS (DTS) > Data Synchronization.

  3. To the right of Data Synchronization Tasks, select the region of the synchronization instance.

Create and configure the task

  1. Click Create Task.

  2. (Optional) Click New Configuration Page in the upper-right corner.

    Skip this step if Back to Previous Version is displayed instead. The new configuration page is recommended.
  3. Configure the source and destination databases.

    Warning

    Read the Limits displayed on the configuration page after filling in the parameters. Skipping this may result in task failures or data inconsistency.

    Source database parameters

    ParameterValue
    Task NameEnter a descriptive name. Names do not need to be unique.
    Select Existing ConnectionOptional. Select a registered DTS database connection to auto-populate parameters. If not using a registered connection, configure the parameters below manually.
    Database TypeSelect Tair/Redis.
    Access MethodSelect Alibaba Cloud Instance.
    Instance RegionSelect the region of the source instance.
    Replicate Data Across Alibaba Cloud AccountsSelect Yesalert notification settings. This supports cross-site communication between Chinese mainland accounts and international accounts.
    Alibaba Cloud AccountEnter the ID of the primary account (Account A) that owns the source instance.
    RAM Role NameEnter the name of the RAM role created in Step 1.
    Instance IDSelect the source instance ID.
    Authentication MethodSelect Password Login or Secret-free login. For secret-free login, make sure password-free access is enabled on the source instance. See Enable password-free access.
    Database PasswordEnter the account credentials. For the default account, enter only the password. For a custom account, use the format <account>:<password> (for example, testaccount:Test1234). Leave blank if no password is set. The account must have read permission. To reset a forgotten password, see Modify or reset the password.
    EncryptionSelect Non-encrypted or SSL-encrypted. For SSL-encrypted self-managed Redis, upload a CA Certificate and enter a CA Key.

    Destination database parameters

    ParameterValue
    Select Existing ConnectionOptional. Select a registered DTS database connection to auto-populate parameters.
    Database TypeSelect Tair/Redis.
    Access MethodSelect Alibaba Cloud Instance.
    Instance RegionSelect the region of the destination instance.
    Replicate Data Across Alibaba Cloud AccountsSelect No. Cross-account access is configured at the source end in this setup.
    Instance IDSelect the destination instance ID.
    Authentication MethodSelect Password Login or Secret-free login. For secret-free login, see Enable password-free access.
    Database PasswordEnter the account credentials. For a custom account, use the format <account>:<password>. The account must have read and write permissions.
    EncryptionSelect Non-encrypted or SSL-encrypted.
  4. Click Test Connectivity and Proceed.

    DTS server CIDR blocks must be added to the security settings of both databases. See Add the CIDR blocks of DTS servers. For self-managed databases, click Test Connectivity in the CIDR Blocks of DTS Servers dialog box.
  5. In the Configure Objects step, set the following parameters:

    ParameterDescription
    Synchronization TypesSelect Full Data Synchronization and Incremental Data Synchronization (recommended together). Full synchronization loads historical data into the destination before incremental sync begins.
    Synchronization TopologySelect One-way Synchronization. This parameter is available only when both instances are Tair Enterprise Edition.
    Processing Mode of Conflicting TablesPrecheck and Report Errors: fails the precheck if the destination already contains data — use this to prevent accidental overwrites. Ignore Errors and Proceed: skips the check and lets source data overwrite matching keys in the destination. This may cause data loss — use with caution.
    Source ObjectsSelect the databases to synchronize and move them to Selected Objects. Select databases only — individual keys cannot be selected.
    Selected ObjectsTo synchronize a specific database (DB 0 to DB 255) or filter by key prefix, right-click the database in Selected Objects and configure the mapping or filter in the Edit Schema dialog box. See Map object names and Specify filter conditions. Multiple object names cannot be mapped at once.
  6. Click Next: Advanced Settings and configure the following:

    ParameterDescription
    Dedicated Cluster for Task SchedulingOptional. Assign the task to a dedicated cluster for improved stability. See What is a DTS dedicated cluster.
    Retry Time for Failed ConnectionsHow long DTS retries after a connection failure. Valid range: 10–1440 minutes. Default: 720. Set to 30 or higher. If reconnection fails within this window, the task fails. A shorter retry time across multiple tasks sharing the same database takes precedence. DTS charges continue during retry periods.
    Retry Time for Other IssuesHow long DTS retries after operation failures (DDL/DML errors). Valid range: 1–1440 minutes. Default: 10. Set to 10 or higher. Must be less than Retry Time for Failed Connections.
    Enable Throttling for Full Data SynchronizationOptional. Limit QPS to the source, RPS, and data transfer speed during full synchronization to reduce load on the destination database server. Available only if Full Data Synchronization is selected.
    Enable Throttling for Incremental Data SynchronizationOptional. Set RPS and transfer speed limits for incremental synchronization.
    Extend Expiration Time of Destination Database KeyAdds extra time (in seconds) to the TTL of keys synchronized to the destination. Applies when using EXPIRE, PEXPIRE, EXPIREAT, or PEXPIREAT commands. If you use this for distributed lock scenarios, locks may not release on time.
    Environment TagOptional. Tags the DTS instance by environment.
    Configure ETLOptional. Enable to apply extract, transform, and load (ETL) logic to data during synchronization. See What is ETL? and Configure ETL in a data migration or data synchronization task.
    Monitoring and AlertingOptional. Configure alerts for task failures or latency threshold breaches. See Configure monitoring and alerting.
  7. Click Next Step: Data Verification to configure data verification. See Configure a data verification task.

  8. Click Next: Save Task Settings and Precheck. DTS runs a precheck before the task starts. If any item fails:

    • Click View Details next to the failed item, resolve the issue, and click Precheck Again.

    • For ignorable alerts, click Confirm Alert Details, then Ignore in the dialog box, and click Precheck Again. Ignoring alerts may result in data inconsistency.

    To preview the API parameters for this task, hover over the button and click Preview OpenAPI parameters before proceeding.
  9. Once Success Rate reaches 100%, click Next: Purchase Instance.

  10. On the purchase page, configure the billing and instance settings:

    ParameterDescription
    Billing MethodSubscription: pay upfront for a fixed term — more cost-effective for long-running tasks. Pay-as-you-go: billed hourly — suitable for short-term use. Release the instance when done to stop charges.
    Resource Group SettingsAssign the instance to a resource group. Default: default resource group. See What is Resource Management?.
    Instance ClassSelect an instance class based on the required synchronization throughput. See Instance classes of data synchronization instances.
    Subscription DurationAvailable only for Subscription billing. Options: 1–9 months, 1 year, 2 years, 3 years, or 5 years.
  11. Read and accept Data Transmission Service (Pay-as-you-go) Service Terms, then click Purchase and Start. In the confirmation dialog box, click OK.

Verify the task

Go to the Data Synchronization page to monitor task progress. If the task includes both full and incremental synchronization, the status shows Incremental Data Synchronization after full synchronization completes.

What's next