AWS ElastiCache in-memory data migration to MemoryDB cluster

412 views Asked by At

I have an ElastiCache cluster (AWS) and I want to migrate my data to a MemoryDB cluster (also in AWS). Seeding the MemoryDB cluster with a ElastiCache snapshot covers the persisted data, but not the in-memory data that was not yet persisted (and potentially changed in the prod cluster).

  • It seems there is no built-in mechanism in Redis to migrate the in-memory data from one cluster to another without downtime or data loss.

  • I've read that ´SLAVEOF´command is in the unavailable commands list in AWS, so promoting a different cluster is not an option.

  • I know the ´redis dump´ and the ´redis-copy´ options too, but there's data loss since they are not incremental.

  • The only way I see is customizing the clients, and make the writes on both clusters while comparing misses. And then wait. At some point the missess would be low enough to stay wit the MemoryDB cluster.

Any other option I may be missing on how to migrate the in-memory data from ElastiCache to MemoryDB w/o data loss or minimal one?

Thanks in advance :)

1

There are 1 answers

0
dllcp On

For consistent async replication from one cluster to another you may be interested in RedisShake. Or consider Envoy to act as a Redis proxy to write to multiple clusters at once.