dragonfly
dragonfly copied to clipboard
Master-slave relationship cannot be established normally
I started two instances of dragonfly on the same machine, and the two instances cannot create a master-slave relationship normally.
The startup commands for the two instances are: nohup dragonfly --requirepass=pwd4dba --bind 10.196.3.191 --port 16667 --dir /home/dba/redis/drogonfly16667/ --maxmemory=16gb --keys_output_limit=12288 --dbfilename dragon.rdb & nohup dragonfly --requirepass=pwd4dba --bind 10.196.3.191 --port 16668 --dir /home/dba/redis/drogonfly16668/ --maxmemory=16gb --keys_output_limit=12288 --dbfilename dragon.rdb &
Confirm that the instance status is normal:
I used the 4.0.11 and 6.0.14 versions of the redis-cli client to try to establish a master-slave relationship with command REPLICAOF
and SLAVEOF
.will throw an error:
(error) ERR could not greet master Bad message

Environment (please complete the following information):
- OS: [Debian GNU/Linux 11]
- Kernel: Linux 5.10.0-18-amd64 SMP Debian 5.10.140-1 (2022-09-02) x86_64 GNU/Linux
- Containerized?: [Bare Metal, Docker, Docker Compose, Docker Swarm, Kubernetes, Other]
- Dragonfly Version: [v1.0.0]
@adiholden we forgot to support authenticated master 🤦🤦🤦
@boomballa meanwhile try without a requirepass flag. We will fix it soon :)
@boomballa meanwhile try without a requirepass flag. We will fix it soon :) @romange Ok, I will try the no-password mode first, and the online environment must still require password authentication 😄
@adiholden First of all thanks for your hard work on the fix. Just now I tried to use the new version to verify the instance with requirepass to try to establish a master-slave relationship, but an error is still reported (error) ERR could not greet master Bad message
,Please guide me on this, is there a problem with my usage method or the bug has not been completely fixed.
Hi @boomballa please path the flag --masterauth=<master_pass> to the replica, this way the replica will know how to auth with master
We will add this to our documentation. Sorry for not writing this before in the issue.
Hi @boomballa please path the flag --masterauth=<master_pass> to the replica, this way the replica will know how to auth with master
We will add this to our documentation. Sorry for not writing this before in the issue.
@adiholden OK, I'll try it out.
@adiholden It has been verified that after configuring --masterauth, the master-slave can be established normally, thanks.