Redis - SPLessons
SPLessons 5 Steps, 3 Clicks
5 Steps - 3 Clicks

Redis Backup

Redis Backup

shape Description

Redis save command is used to create back up of current redis database. The goal of this is to give a basic understanding of what exactly Redis does and how it differs from other database,both relational and NoSQL and equip the user with the knowledge and need to able to start using Redis with a real application. But has to be feel comfortable enough with Redis, and explain how Redis work to decide if Redis would be a good choice for a data store for the application. Redis actually run on the server for configuring file it actually is going to require a password for utilizing the command line interface and equip the user with the knowledge and need to able to start using Redis with a real application. But has to be feel comfortable enough with Redis, and explain how Redis work to decide if Redis would be a good choice for a data store for the application.

shape Syntax

The basic syntax for Redis save command is as follows:
127.0.0.1:6379> SAVE

Example

shape Description

The sample example for backing up the present database is as follows [c] 127.0.0.1:6379> SAVE OK [/c]

Restore and Bgsave data

shape Description

To restore redis data just move dump.rdb redis backup file into the redis directory and start the server. To create redis backup alternate command BGSAVE is also available. This command will start the backup process and run this in background.

Example

shape Description

The sample example for restoring the present database is as follows [c] 127.0.0.1:6379> CONFIG get dir "dir" "/user/tutorialspoint/redis-2.8.13/src" 127.0.0.1:6379> BGSAVE Background saving started [/c]

Summary

shape Key Points

  • Backup - Redis save command is used to create the backup of the current redis database.
  • Restore - Is used to move the dump.rdb back file.
  • Bgsave data - Alterate to redis backup.