简体   繁体   English

Elasticsearch&NetFlix Edda-NoNodeAvailableException:无可用节点

[英]Elasticsearch & NetFlix Edda - NoNodeAvailableException: No node available

I am trying to get Netflix open source solution Edda to work with Elasticsearch. 我正在尝试让Netflix开源解决方案Edda与Elasticsearch一起使用。 I know I've installed Edda correctly because I can get it working with MongoDB as a backend successfully. 我知道我已经正确安装了Edda,因为我可以成功地将它与MongoDB作为后端一起使用。 I'd prefer to use Elasticsearch so I can get the benefits of Kibana rather than write my own frontend. 我更喜欢使用Elasticsearch,这样我可以获得Kibana的好处,而不是编写自己的前端。 So I'm running Edda and Elasticsearch on the same server in AWS at the moment (just trying to get it working). 因此,我目前正在AWS的同一台服务器上运行Edda和Elasticsearch(只是试图使其工作)。 Elasticsearch is operational: Elasticsearch是可操作的:

{
  "name" : "Arsenic",
  "cluster_name" : "elasticsearch",
  "version" : {
    "number" : "2.1.0",
    "build_hash" : "72cd1f1a3eee09505e036106146dc1949dc5dc87",
    "build_timestamp" : "2015-11-18T22:40:03Z",
    "build_snapshot" : false,
    "lucene_version" : "5.3.1"
  },
  "tagline" : "You Know, for Search"
}

And to show it's listening: 并显示它正在监听:

netstat -tulpn | grep java
tcp        0      0 ::ffff:<myip>:9300    :::*                        LISTEN      2270/java
tcp        0      0 ::ffff:<myip>:9200    :::*                        LISTEN      2270/java

My java version I updated from 1.7 to 1.8 as I believe the java version for Elasticsearch and what is running on the server have to match. 我的Java版本从1.7更新到1.8,因为我相信Elasticsearch的Java版本和服务器上运行的版本必须匹配。 I can't see a reason why 1.8 would be causing an issue: 我看不出1.8会引起问题的原因:

java -version
openjdk version "1.8.0_65"
OpenJDK Runtime Environment (build 1.8.0_65-b17)
OpenJDK 64-Bit Server VM (build 25.65-b01, mixed mode)

Here's my edda properties file: 这是我的edda属性文件:

cat /home/ec2-user/edda/src/main/resources/edda.properties | grep elasticsearch
edda.datastore.current.class=com.netflix.edda.elasticsearch.ElasticSearchDatastore
edda.elector.class=com.netflix.edda.elasticsearch.ElasticSearchElector
edda.elasticsearch.cluster=elasticsearch
edda.elasticsearch.address=<myip>:9300
edda.elasticsearch.shards=5
edda.elasticsearch.replicas=0
# http://www.elasticsearch.org/guide/reference/api/index_/
edda.elasticsearch.writeConsistency=quorum
edda.elasticsearch.replicationType=async
edda.elasticsearch.scanBatchSize=1000
edda.elasticsearch.scanCursorDuration=60000
edda.elasticsearch.bulkBatchSize=0

And in my elasticsearch.yml file: 在我的elasticsearch.yml文件中:

network.host: <myip>

I haven't specified a clustername so it assumes the default 'elasticseach'. 我尚未指定集群名称,因此它假定默认的'elasticseach'。

So when I run Edda to poll AWS and populate elasticsearch with the data it finds I receive this error: 因此,当我运行Edda轮询AWS并用它的数据填充elasticsearch时,我收到此错误:

[Collection aws.hostedZones] init: caught org.elasticsearch.client.transport.NoNodeAvailableException: No node available
        at com.netflix.edda.Collection$$anonfun$init$1.apply$mcV$sp(Collection.scala:471)
        at com.netflix.edda.Utils$$anon$1.act(Utils.scala:169)
        at scala.actors.Reactor$$anonfun$dostart$1.apply(Reactor.scala:224)
        at scala.actors.Reactor$$anonfun$dostart$1.apply(Reactor.scala:224)
        at scala.actors.ReactorTask.run(ReactorTask.scala:33)
        at scala.actors.ReactorTask.compute(ReactorTask.scala:63)
        at scala.concurrent.forkjoin.RecursiveAction.exec(RecursiveAction.java:160)
        at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
        at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
        at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
        at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)

Clearly it can't connect to the elasticsearch cluster yet the cluster name is correct, it's listening on the correct port and ip address as far as I can tell and I don't think there's an issue with the java version. 显然,它无法连接到Elasticsearch集群,但集群名称正确,据我所知,它正在侦听正确的端口和IP地址,并且我认为Java版本没有问题。

I'm missing something probably very simple. 我想念的东西可能很简单。

Thanks in advance for all your assistance. 在此先感谢您的协助。

Regards Neilos 问候内洛斯

I've figured it out, the java client used in Edda is set to use version 0.90.0 of elasticsearch which is set in build.gradle, if you install that version of Elasticsearch it works. 我已经弄清楚了,如果您安装该版本的Elasticsearch,则Edda中使用的Java客户端设置为使用build.gradle中设置的elasticsearch版本0.90.0。 Obviously that's a very old version of Elasticsearch which you are not likely to want to use. 显然,这是Elasticsearch的非常旧的版本,您不太可能要使用。 If you change the version number in this file it fails when it tries to compile due to broken paths (missing assemblies). 如果更改此文件中的版本号,则由于路径中断(缺少程序集)而尝试编译时将失败。 I'm weighing up whether it's worth trying to resolve these assembly issues to get it working with the latest version of Elasticsearch or choose to use MongoDB which works without any code changes but will only provide REST Api functionality. 我正在权衡是否值得尝试解决这些程序集问题以使其与最新版本的Elasticsearch一起使用,还是选择使用MongoDB,该功能无需任何代码更改即可工作,而仅提供REST Api功能。 At least the problem is resolved. 至少问题已解决。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 ElasticSearch Java API:NoNodeAvailableException:没有可用的节点 - ElasticSearch Java API:NoNodeAvailableException: No node available elasticserch:org.elasticsearch.client.transport.NoNodeAvailableException:没有可用的节点 - elasticserch: org.elasticsearch.client.transport.NoNodeAvailableException: No node available NoNodeAvailableException:没有节点可用于执行查询 - NoNodeAvailableException: No node was available to execute the query Elasticsearch NoNodeAvailableException没有配置的节点可用 - Elasticsearch NoNodeAvailableException None of the configured nodes are available 启动声纳时,出现以下异常:org.elasticsearch.client.transport.NoNodeAvailableException:无可用节点 - When starting sonar, I get the following exception: org.elasticsearch.client.transport.NoNodeAvailableException: No node available NoNodeAvailableException [没有已配置的节点可用]在Elasticsearch 5.1.2中 - NoNodeAvailableException[None of the configured nodes are available] in Elasticsearch 5.1.2 线程“主”中的异常org.elasticsearch.client.transport.NoNodeAvailableException:无可用节点 - Exception in thread “main” org.elasticsearch.client.transport.NoNodeAvailableException: No node available Elasticsearch - NoNodeAvailableException - Elasticsearch - NoNodeAvailableException org.elasticsearch.client.transport.NoNodeAvailableException:没有配置的节点可用:[] - org.elasticsearch.client.transport.NoNodeAvailableException: None of the configured nodes are available: [] Elasticsearch:“无法获取 {IP} 的节点信息”和服务日志中的“noNodeAvailableException” - Elasticsearch : “failed to get node info for {IP}” and “noNodeAvailableException” in service log
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM