配置认证密码
一丶在redis.conf添加密码
使用"requirepass mypass"配置密码
二丶使用该配置启动redis
redis-server ./redis.conf
三丶验证
1) 没有使用密码登录
2) 使用密码认证
学习资料:
官方文档
Redis 配置密码认证