前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >try to re connect to a new server ,server is not appointed,will choose a random server

try to re connect to a new server ,server is not appointed,will choose a random server

作者头像
johnhuster的分享
发布2022-09-16 12:36:52
5.1K0
发布2022-09-16 12:36:52
举报
文章被收录于专栏:johnhuster

k8s集群部署的nacos服务接连收到很多nacos-client抛出的更新服务状态异常:

2022-07-23 10:46:39.997  INFO 7 --- [t.remote.worker] com.alibaba.nacos.common.remote.client   : [7b83a82c-d533-4968-9f39-a1d8719f712a]Server healthy check fail,currentConnection=1658453921079_10.233.92.39_47188 2022-07-23 10:46:39.998  INFO 7 --- [t.remote.worker] com.alibaba.nacos.common.remote.client   : [7b83a82c-d533-4968-9f39-a1d8719f712a] try to re connect to a new server ,server is  not appointed,will choose a random server. 2022-07-23 10:46:39.999  INFO 7 --- [t.remote.worker] com.alibaba.nacos.common.remote.client   : [config-0-bae787c4-fa18-4b14-b221-2eb3eed3a68f]Server healthy check fail,currentConnection=1658453909331_10.233.92.39_47058 2022-07-23 10:46:39.999  INFO 7 --- [t.remote.worker] com.alibaba.nacos.common.remote.client   : [config-0-bae787c4-fa18-4b14-b221-2eb3eed3a68f] try to re connect to a new server ,server is  not appointed,will choose a random server. 2022-07-23 10:46:46.119  INFO 7 --- [t.remote.worker] com.alibaba.nacos.common.remote.client   : [7b83a82c-d533-4968-9f39-a1d8719f712a] fail to connect server,after trying 1 times, last try server is {serverIp='nacos-server.xxx', server main port=8848},error=unknown 2022-07-23 10:46:46.120  INFO 7 --- [t.remote.worker] com.alibaba.nacos.common.remote.client   : [config-0-bae787c4-fa18-4b14-b221-2eb3eed3a68f] fail to connect server,after trying 1 times, last try server is {serverIp='nacos-server.xxx', server main port=8848},error=unknown 2022-07-23 10:46:48.713 ERROR 7 --- [aming.updater.0] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceQueryRequest{headers={app=unknown}, requestId='null'}, retryTimes=0,errorMessage=Client not connected,current status:UNHEALTHY 2022-07-23 10:46:48.813 ERROR 7 --- [aming.updater.0] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceQueryRequest{headers={app=unknown}, requestId='null'}, retryTimes=1,errorMessage=Client not connected,current status:UNHEALTHY 2022-07-23 10:46:48.914 ERROR 7 --- [aming.updater.0] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceQueryRequest{headers={app=unknown}, requestId='null'}, retryTimes=2,errorMessage=Client not connected,current status:UNHEALTHY 2022-07-23 10:46:48.914  WARN 7 --- [aming.updater.0] com.alibaba.nacos.client.naming          : [NA] failed to update serviceName: DEFAULT_GROUP@@iot-devicemgr

com.alibaba.nacos.api.exception.NacosException: Request nacos server failed:      at com.alibaba.nacos.client.naming.remote.gprc.NamingGrpcClientProxy.requestToServer(NamingGrpcClientProxy.java:213)     at com.alibaba.nacos.client.naming.remote.gprc.NamingGrpcClientProxy.queryInstancesOfService(NamingGrpcClientProxy.java:128)     at com.alibaba.nacos.client.naming.remote.NamingClientProxyDelegate.queryInstancesOfService(NamingClientProxyDelegate.java:111)     at com.alibaba.nacos.client.naming.core.ServiceInfoUpdateServiceUpdateTask.run(ServiceInfoUpdateService.java:182)     at java.base/java.util.concurrent.ExecutorsRunnableAdapter.call(Executors.java:515)     at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)     at java.base/java.util.concurrent.ScheduledThreadPoolExecutorScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)     at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)     at java.base/java.util.concurrent.ThreadPoolExecutorWorker.run(ThreadPoolExecutor.java:628)     at java.base/java.lang.Thread.run(Thread.java:829) Caused by: com.alibaba.nacos.api.exception.NacosException: Client not connected,current status:UNHEALTHY     at com.alibaba.nacos.common.remote.client.RpcClient.request(RpcClient.java:628)     at com.alibaba.nacos.common.remote.client.RpcClient.request(RpcClient.java:608)     at com.alibaba.nacos.client.naming.remote.gprc.NamingGrpcClientProxy.requestToServer(NamingGrpcClientProxy.java:203)     ... 9 common frames omitted

nacos github项目上确实有人提出nacos-2.0.1版本出现过类似的问题,但是我们遇到的情况跟这个不是太一样,最终发现出现这个问题的原因在于ip地址的冲突,又看了部署在其他两个节点的服务nacos-client客户端没有抛出上面的异常信息。于是修改对应的ip后就没有上述异常信息抛出了。

发现ip地址冲突可以通过arping命令实现:

本文参与 腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
原始发表:2022-07-24,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
相关产品与服务
对象存储
对象存储(Cloud Object Storage,COS)是由腾讯云推出的无目录层次结构、无数据格式限制,可容纳海量数据且支持 HTTP/HTTPS 协议访问的分布式存储服务。腾讯云 COS 的存储桶空间无容量上限,无需分区管理,适用于 CDN 数据分发、数据万象处理或大数据计算与分析的数据湖等多种场景。
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档