redis: backing up dump.rdb

后端 未结 2 1578
挽巷
挽巷 2021-02-03 21:13

Context

I have a live running redis-server.

I want to make a backup.

Idea:

I want to do the following:

cp dump.rdb ~/some-oth         


        
相关标签:
2条回答
  • 2021-02-03 21:31

    If you using Amazon S3, it's very simple to backup Redis database with s3cmd tool.

    s3cmd: http://s3tools.org/s3cmd

    Tutorial: http://guchex.com/viniciusfbm/post/50/how-to-backup-redis-database-encrypted-to-s3-via-command-line-ubuntu

    0 讨论(0)
  • 2021-02-03 21:44

    From http://redis.io/topics/persistence

    Redis is very data backup friendly since you can copy RDB files while the database is running: the RDB is never modified once produced, and while it gets produced it uses a temporary name and is renamed into its final destination atomically using rename(2) only when the new snapshot is complete.

    So, the correct way is to simply copy the dump.rdb to your backup location.

    0 讨论(0)
提交回复
热议问题