O'Reilly logo

Redis 4.x Cookbook by Zuofei Wang, Pengcheng Huang

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

How to do it...

To show how to perform the trouble shot of replication issue, take the following steps:

  1. Open a console and get replication information for the master and slave Redis instance using redis-cli:
$ bin/redis-cli -p 6379 info Replication # Replication role:master connected_slaves:1 slave0:ip=127.0.0.1,port=6380,state=online,offset=1288,lag=1 master_replid:8f7b9821477006200651baef11d6af7451dede3d master_replid2:0000000000000000000000000000000000000000 master_repl_offset:1288 second_repl_offset:-1 repl_backlog_active:1 repl_backlog_size:1048576 repl_backlog_first_byte_offset:1 repl_backlog_histlen:1288 $ bin/redis-cli -p 6380 info Replication # Replication role:slave master_host:127.0.0.1 master_port:6379 master_link_status:up ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required