修改/etc/redis.conf 一定要强密码redis为内存存储 抗暴力破解强
requirepass password
systemctl restart redis
# redis-cli
12⑦0.0.1:6379> set username 'leoshi'
(error) NOAUTH Authentication required.
12⑦0.0.1:6379> AUTH 123456
(error) ERR invalid password
12⑦0.0.1:6379> AUTH password
OK
12⑦0.0.1:6379> set username 'leoshi'
OK
# redis-cli -h 12⑦0.0.1 -p 6379 -a password
12⑦0.0.1:6379> set baidu "www.baidu.com"
OK
以上就是土嘎嘎小编大虾米为大家整理的相关主题介绍,如果您觉得小编更新的文章只要能对粉丝们有用,就是我们最大的鼓励和动力,不要忘记讲本站分享给您身边的朋友哦!!