redis.conf中
requirepass 123456
如果再次访问时,有异常。
127.0.0.1:6379> set ab abcc
(error) NOAUTH Authentication required.
这是提示要输入密码
127.0.0.1:6379> auth 123456
OK
127.0.0.1:6379> set ab abcc
OK
127.0.0.1:6379> get ab
redis.conf中
requirepass 123456
如果再次访问时,有异常。
127.0.0.1:6379> set ab abcc
(error) NOAUTH Authentication required.
这是提示要输入密码
127.0.0.1:6379> auth 123456
OK
127.0.0.1:6379> set ab abcc
OK
127.0.0.1:6379> get ab