Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

服务端启动报ERR Client sent AUTH, but no password is set #29

Closed
ghzengqy568 opened this issue Mar 31, 2021 · 1 comment
Closed
Projects

Comments

@ghzengqy568
Copy link
Collaborator

org.springframework.data.redis.RedisConnectionFailureException: Unable to connect to Redis; nested exception is io.lettuce.core.RedisConnectionException: Unable to connect to x.x.x.x:x
at org.springframework.data.redis.connection.lettuce.LettuceConnectionFactory$ExceptionTranslatingConnectionProvider.translateException(LettuceConnectionFactory.java:1553) ~[spring-data-redis-2.4.1.jar:2.4.1]
....
Caused by: io.lettuce.core.RedisCommandExecutionException: ERR Client sent AUTH, but no password is set
at io.lettuce.core.internal.ExceptionFactory.createExecutionException(ExceptionFactory.java:137) ~[lettuce-core-6.0.1.RELEASE.jar:6.0.1.RELEASE]
at io.lettuce.core.internal.ExceptionFactory.createExecutionException(ExceptionFactory.java:110) ~[lettuce-core-6.0.1.RELEASE.jar:6.0.1.RELEASE]
at io.lettuce.core.protocol.AsyncCommand.completeResult(AsyncCommand.java:120) ~[lettuce-core-6.0.1.RELEASE.jar:6.0.1.RELEASE]

@ghzengqy568
Copy link
Collaborator Author

ghzengqy568 commented Mar 31, 2021

后端服务连接redis过程中默认提供了密码访问, 如果你的redis 不需要密码访问,而又提供了spring.redis.password, 此时将会导致RedisConnectionFailureException异常, 希望在application.yml中去掉spring.redis.password配置项, 由不同环境(如application-dev.yml)根据自己环境决定添加spring.redis.password配置

@ghzengqy568 ghzengqy568 added this to In progress in 1.0.4 Apr 1, 2021
@ghzengqy568 ghzengqy568 moved this from In progress to Done in 1.0.4 Apr 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
1.0.4
Done
Development

No branches or pull requests

1 participant