redis 6中的主副本同步需要哪些acl命令?

yquaqz18  于 2021-06-10  发布在  Redis
关注(0)|答案(0)|浏览(479)

在群集环境中使用acl配置redis 6时,必须创建一个额外的用户(假设不需要默认用户或该用户无权访问psync命令)。必须分配给此用户的确切命令是什么?
文档中有一个关于sentinel和replica的acl规则的小注解,指出sentinel需要:
auth,client,subscribe,script,publish,ping,info,multi,slaveof,config,client,exec(身份验证,客户端,订阅,脚本,发布,ping,信息,多,从属,配置,客户端,执行)
副本需要:
psync、replconf、ping
我最好的猜测是将两者结合起来,形成一个命令集:
auth,client,subscribe,script,publish,ping,info,multi,slaveof,config,client,exec,psync,replconf
摘自redis.conf,其中指出“和/或复制所需的其他命令”:


# If the master is password protected (using the "requirepass" configuration

# directive below) it is possible to tell the replica to authenticate before

# starting the replication synchronization process, otherwise the master will

# refuse the replica request.

# 

masterauth mymasterpassword

# 

# However this is not enough if you are using Redis ACLs (for Redis version

# 6 or greater), and the default user is not capable of running the PSYNC

# command and/or other commands needed for replication. In this case it's

# better to configure a special user to use with replication, and specify the

# masteruser configuration as such:

# 

masteruser mymasteruser

# 

# When masteruser is specified, the replica will authenticate against its

# master using the new AUTH form: AUTH <username> <password>.

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题