当SpringBoot项目尝试连接Redis服务器时遇到`ERR Clientsent AUTH but no password is set`错误,可能是因为Redis配置未正确加载。尽管redis.conf文件中设定了密码,但启动Redis时未指定配置文件导致问题发生。解决方法是在启动Redis服务时明确指定配置文件路径,如`./redis-server ../redis.conf`,重新连接后问题即可得到解决。
问题描述:用springboot项目连接服务器的redis时,报错:Caused by: io.lettuce.core.RedisCommandExecutionException: ERR Client sent AUTH, but no password is set