Hello!

I see in the Redis 7 changelog that the RDB format changed and is no longer backwards compatible with the old format.

We discovered this issue while upgrading from Redis 6.x -> 7.0. The workaround was to drop the old RDB file and start the new server; however, this results in data loss.

Is there a recommended migration path for upgrading to 7.0 in a way that preserves the previous state?

I searched the other forums and didn't find any other solutions than "just drop the RDB file".

I'm also considering these approaches and was wondering which might be most suitable:

  1. Stop using RDB-based persistence :)
  2. Drop the old RDB file and rely on AOF-based persistence instead. We could re-enable RDB persistence after Redis 7 is started and state is restored from AOF files.
  3. Use the Redis-RDB-CLI somehow to migrate the old RDB format to the new format? Are there any other such migration scripts that could be used and some guide on the best way to do this?
  4. Launch a Redis 6.x and Redis 7 cluster side-by-side and somehow replicate the data between them. Is that possible?

Thanks for any guidance or pointers you can provide!

Comment From: sundb

Incompatibility means that older versions redis can't use the rdb file generated by newer version redis. But newer version redis do support older rdb files and will automatically convert older rdb files to newer versions.

Comment From: oranagra

We discovered this issue while upgrading from Redis 6.x -> 7.0. The workaround was to drop the old RDB file and start the new server; however, this results in data loss.

@burkestar as stated, upgrades should work seamlessly, it's downgrades that are not possible. please describe what problems you actually run into during upgrade.

Comment From: burkestar

Ok I think we now understand the problem. We started running our app with 7.0 (which migrated the RDB file to the new format), switched branches which went back to using Redis 6.x and got the error about "can't handle RDB format version 10".

So the missing piece was that Redis 7 will correctly migrate the RDB file in place to the new format, which was not immediately clear from the 7.0 release notes (although in retrospect, it was implied).

Thanks for your help in clarifying this!