赞
踩
注册中心地址:redis://192.168.21.19:6379?auth=root:123123
2018-01-08 19:22:31,485 main - [DUBBO] Failed to register dubbo://192.168.2.196:30012/com.lanmei.service.UserService?anyhost=true&application=wbq_provider&dubbo=2.5.4-SNAPSHOT&generic=false&interface=com.lanmei.service.UserService&loadbalance=roundrobin&methods=getUserId,dkqbReg,memberList,loanMobileExists,userMobileExists,setNickName,logout,pushSet,iforgot,reg,qrcode,login,setInfo&owner=wbq&pid=13640&retries=0&revision=1.0.1-SNAPSHOT&side=provider&timeout=30000×tamp=1515410551210 to registry 192.168.21.19:6379, cause: Failed to register service to redis registry. registry: 192.168.21.19:6379, service: dubbo://192.168.2.196:30012/com.lanmei.service.UserService?anyhost=true&application=wbq_provider&dubbo=2.5.4-SNAPSHOT&generic=false&interface=com.lanmei.service.UserService&loadbalance=roundrobin&methods=getUserId,dkqbReg,memberList,loanMobileExists,userMobileExists,setNickName,logout,pushSet,iforgot,reg,qrcode,login,setInfo&owner=wbq&pid=13640&retries=0&revision=1.0.1-SNAPSHOT&side=provider&timeout=30000×tamp=1515410551210, cause: Could not get a resource from the pool, dubbo version: 2.5.4-SNAPSHOT, current host: 127.0.0.1
java.lang.IllegalStateException: Failed to register dubbo://192.168.2.196:30012/com.lanmei.service.UserService?anyhost=true&application=wbq_provider&dubbo=2.5.4-SNAPSHOT&generic=false&interface=com.lanmei.service.UserService&loadbalance=roundrobin&methods=getUserId,dkqbReg,memberList,loanMobileExists,userMobileExists,setNickName,logout,pushSet,iforgot,reg,qrcode,login,setInfo&owner=wbq&pid=13640&retries=0&revision=1.0.1-SNAPSHOT&side=provider&timeout=30000×tamp=1515410551210 to registry 192.168.21.19:6379, cause: Failed to register service to redis registry. registry: 192.168.21.19:6379, service: dubbo://192.168.2.196:30012/com.lanmei.service.UserService?anyhost=true&application=wbq_provider&dubbo=2.5.4-SNAPSHOT&generic=false&interface=com.lanmei.service.UserService&loadbalance=roundrobin&methods=getUserId,dkqbReg,memberList,loanMobileExists,userMobileExists,setNickName,logout,pushSet,iforgot,reg,qrcode,login,setInfo&owner=wbq&pid=13640&retries=0&revision=1.0.1-SNAPSHOT&side=provider&timeout=30000×tamp=1515410551210, cause: Could not get a resource from the pool2018-01-08 19:22:31,492 DubboShutdownHook - [DUBBO] Unexport service: injvm://127.0.0.1/com.lanmei.service.UserService?anyhost=true&application=wbq_provider&dubbo=2.5.4-SNAPSHOT&generic=false&interface=com.lanmei.service.UserService&loadbalance=roundrobin&methods=getUserId,dkqbReg,memberList,loanMobileExists,userMobileExists,setNickName,logout,pushSet,iforgot,reg,qrcode,login,setInfo&owner=wbq&pid=13640&retries=0&revision=1.0.1-SNAPSHOT&side=provider&timeout=30000×tamp=1515410551210, dubbo version: 2.5.4-SNAPSHOT, current host: 127.0.0.1
dubbo提供者注册redis导致ERR invalid password原因:
1.没有用户名的情况下,redis注册地址不对,修改为redis://192.168.21.19:6379?auth=123123即可
*dubbo进行redis注册时auth=后面跟上"用户名:认证密码",没有用户名时,auth=后面跟上"认证密码"即可。
*本文是在工作中遇到的问题,解决方式也因开发环境不同而不同。本文仅作为参考,不喜勿喷。
redis认证密码两种设置方式:
1.修改redis.conf中requirepass为123123
2.运行./redis-cli 通过config set requirepass foobared设置
3.需重启
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。