Limited Time Offer!

For Less Than the Cost of a Starbucks Coffee, Access All DevOpsSchool Videos on YouTube Unlimitedly.
Master DevOps, SRE, DevSecOps Skills!

Enroll Now

How to backup / dump & Restore redis database?


$ redis-cli
127.0.0.1:6379> auth mypassword
127.0.0.1:6379> CONFIG GET dir
127.0.0.1:6379> SAVE
127.0.0.1:6379> quit

This ensures dump.rdb is completely up-to-date, and shows us where it is stored (/var/lib/redis/dump.rdb in this case). dump.rdb is also periodically written to disk automatically.

$ cd /var/lib/redis
$ cat dump.rdb

dump.rdb is your redis backup file

Rajesh Kumar
Follow me
Latest posts by Rajesh Kumar (see all)
Subscribe
Notify of
guest
0 Comments
Newest
Oldest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x