Back to results for “Cluster Sharding & Hash Slots”
Redis › Redis Replication

What is Redis replication, and how does it help improve availability and read scalability?

Beginner

Answer

Redis replication lets you create one or more replica servers that maintain a continuously synchronized copy of a primary server's data, providing a backup that can take over if the primary fails, and also letting you distribute read traffic across the replicas to reduce load on the primary server.
-- On the replica server
REPLICAOF primary_host 6379
Real-world example A busy application directs its read heavy reporting queries to a replica server while all writes go to the primary, reducing the load on the primary server and improving overall responsiveness.

Common follow-ups: Can replicas accept write operations directly?;How much delay is typical between a write on the primary and it appearing on a replica?