org.elasticsearch.client.transport.NoNodeAvailableException
Elasticsearch | 作者 fengsasa | 发布于2016年11月10日 | 阅读数:7064
集群节点数:4
集群健康值:green (10 of 10)
不知道哪里配置不对了,在数据索引进行插入中报错,在查看了很多文档资料后没有解决此问题,具体报错如下:
Exception in thread "main" org.elasticsearch.client.transport.NoNodeAvailableException: None of the configured nodes are available:
at org.elasticsearch.client.transport.TransportClientNodesService.ensureNodesAreAvailable(TransportClientNodesService.java:278)
at org.elasticsearch.client.transport.TransportClientNodesService.execute(TransportClientNodesService.java:197)
at org.elasticsearch.client.transport.support.InternalTransportClient.execute(InternalTransportClient.java:106)
at org.elasticsearch.client.support.AbstractClient.bulk(AbstractClient.java:163)
at org.elasticsearch.client.transport.TransportClient.bulk(TransportClient.java:364)
at org.elasticsearch.action.bulk.BulkRequestBuilder.doExecute(BulkRequestBuilder.java:164)
at org.elasticsearch.action.ActionRequestBuilder.execute(ActionRequestBuilder.java:91)
at org.elasticsearch.action.ActionRequestBuilder.execute(ActionRequestBuilder.java:65)
at com.hansight.utils.EsUtils.importData(EsUtils.java:134)
at com.hansight.utils.EsUtils.main(EsUtils.java:173)
只有主节点内容变化,子节点内容不变只显示启动后的日志?不知道是不是这样的。。。
主节点日志内容如下(IP地址已修改为*):
[2016-11-10 08:14:17,738][INFO ][gateway ] [master] recovered [0] indices into cluster_state
[2016-11-10 08:14:31,907][INFO ][cluster.service ] [master] added {[node1][GTjLwR3nRJePsq_iwWr7Kw][node1][inet[/***.**.***.***:9300]],}, reason: zen-disco-receive(join from node[[node1][GTjLwR3nRJePsq_iwWr7Kw][node1][inet[/***.**.***.***:9300]]])
[2016-11-10 08:14:36,887][INFO ][cluster.service ] [master] added {[node2][WMBJTHm9QKOgrR_Wa4Aplg][node2][inet[/***.**.***.***:9300]],}, reason: zen-disco-receive(join from node[[node2][WMBJTHm9QKOgrR_Wa4Aplg][node2][inet[/***.**.***.***:9300]]])
[2016-11-10 08:14:46,124][INFO ][cluster.service ] [master] added {[node3][A8urHK3zR0aPkae0uajxBQ][node3][inet[/***.**.***.***:9300]],}, reason: zen-disco-receive(join from node[[node3][A8urHK3zR0aPkae0uajxBQ][node3][inet[/***.**.***.***:9300]]])
[2016-11-10 08:16:56,719][INFO ][cluster.metadata ] [master] [test_logs] creating index, cause [auto(bulk api)], shards [5]/[1], mappings []
[2016-11-10 08:16:58,630][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
[2016-11-10 08:16:58,841][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
[2016-11-10 08:17:04,409][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
[2016-11-10 08:17:26,237][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
[2016-11-10 08:17:52,582][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
[2016-11-10 09:09:02,692][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
集群健康值:green (10 of 10)
不知道哪里配置不对了,在数据索引进行插入中报错,在查看了很多文档资料后没有解决此问题,具体报错如下:
Exception in thread "main" org.elasticsearch.client.transport.NoNodeAvailableException: None of the configured nodes are available:
at org.elasticsearch.client.transport.TransportClientNodesService.ensureNodesAreAvailable(TransportClientNodesService.java:278)
at org.elasticsearch.client.transport.TransportClientNodesService.execute(TransportClientNodesService.java:197)
at org.elasticsearch.client.transport.support.InternalTransportClient.execute(InternalTransportClient.java:106)
at org.elasticsearch.client.support.AbstractClient.bulk(AbstractClient.java:163)
at org.elasticsearch.client.transport.TransportClient.bulk(TransportClient.java:364)
at org.elasticsearch.action.bulk.BulkRequestBuilder.doExecute(BulkRequestBuilder.java:164)
at org.elasticsearch.action.ActionRequestBuilder.execute(ActionRequestBuilder.java:91)
at org.elasticsearch.action.ActionRequestBuilder.execute(ActionRequestBuilder.java:65)
at com.hansight.utils.EsUtils.importData(EsUtils.java:134)
at com.hansight.utils.EsUtils.main(EsUtils.java:173)
只有主节点内容变化,子节点内容不变只显示启动后的日志?不知道是不是这样的。。。
主节点日志内容如下(IP地址已修改为*):
[2016-11-10 08:14:17,738][INFO ][gateway ] [master] recovered [0] indices into cluster_state
[2016-11-10 08:14:31,907][INFO ][cluster.service ] [master] added {[node1][GTjLwR3nRJePsq_iwWr7Kw][node1][inet[/***.**.***.***:9300]],}, reason: zen-disco-receive(join from node[[node1][GTjLwR3nRJePsq_iwWr7Kw][node1][inet[/***.**.***.***:9300]]])
[2016-11-10 08:14:36,887][INFO ][cluster.service ] [master] added {[node2][WMBJTHm9QKOgrR_Wa4Aplg][node2][inet[/***.**.***.***:9300]],}, reason: zen-disco-receive(join from node[[node2][WMBJTHm9QKOgrR_Wa4Aplg][node2][inet[/***.**.***.***:9300]]])
[2016-11-10 08:14:46,124][INFO ][cluster.service ] [master] added {[node3][A8urHK3zR0aPkae0uajxBQ][node3][inet[/***.**.***.***:9300]],}, reason: zen-disco-receive(join from node[[node3][A8urHK3zR0aPkae0uajxBQ][node3][inet[/***.**.***.***:9300]]])
[2016-11-10 08:16:56,719][INFO ][cluster.metadata ] [master] [test_logs] creating index, cause [auto(bulk api)], shards [5]/[1], mappings []
[2016-11-10 08:16:58,630][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
[2016-11-10 08:16:58,841][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
[2016-11-10 08:17:04,409][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
[2016-11-10 08:17:26,237][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
[2016-11-10 08:17:52,582][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
[2016-11-10 09:09:02,692][INFO ][cluster.metadata ] [master] [test_logs] update_mapping [logs] (dynamic)
4 个回复
ybtsdst - focus on lucene & es
赞同来自:
fengsasa - 单车骑行
赞同来自:
AlixMu - Elasticsearch小轿车司机
赞同来自:
fengsasa - 单车骑行
赞同来自:
Settings settings = ImmutableSettings.settingsBuilder()
.put("client.transport.sniff", true).build();
TransportClientclient = new TransportClient(settings);
可能是因为监控集群的状态,当某一个节点短暂停掉以后误以为整个集群的挂掉,不知道是不是这个原因,还没有具体确定,目前是把这个设置取消后就正常将数据进行索引了,数据量30G,数据条数22719994