Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/sql-server-2005/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Amazon web services ElasticSearch云aws插件无法加入群集_Amazon Web Services_Amazon Ec2_<img Src="//i.stack.imgur.com/A3TTx.png" Height="16" Width="18" Alt="" Class="sponsor Tag Img">elasticsearch Plugin - Fatal编程技术网 elasticsearch-plugin,Amazon Web Services,Amazon Ec2,elasticsearch Plugin" /> elasticsearch-plugin,Amazon Web Services,Amazon Ec2,elasticsearch Plugin" />

Amazon web services ElasticSearch云aws插件无法加入群集

Amazon web services ElasticSearch云aws插件无法加入群集,amazon-web-services,amazon-ec2,elasticsearch-plugin,Amazon Web Services,Amazon Ec2,elasticsearch Plugin,因此,我一直在尝试使用ElasticSearch“cloud aws”插件将ElasticSearch节点连接到我的单个主节点。我已经阅读了一些在线指南,并尝试了各种来源的一些设置,但我仍然无法让新节点加入现有的主节点 我已经为EC2配置了IAMS角色和标记,这是一个节点上的elasticsearch.yml文件(其他节点类似): elasticsearch的日志记录很差,即使在调试模式下也没有提供多少 [2016-03-15 23:01:05,440][INFO ][node

因此,我一直在尝试使用ElasticSearch“cloud aws”插件将ElasticSearch节点连接到我的单个主节点。我已经阅读了一些在线指南,并尝试了各种来源的一些设置,但我仍然无法让新节点加入现有的主节点

我已经为EC2配置了IAMS角色和标记,这是一个节点上的elasticsearch.yml文件(其他节点类似):

elasticsearch的日志记录很差,即使在调试模式下也没有提供多少

[2016-03-15 23:01:05,440][INFO ][node                     ] [Thor] version[2.2.0], pid[1550], build[8ff36d1/2016-01-27T13:32:39Z]
[2016-03-15 23:01:05,447][INFO ][node                     ] [Thor] initializing ...
[2016-03-15 23:01:06,685][INFO ][plugins                  ] [Thor] modules     [lang-expression, lang-groovy], plugins [cloud-aws], sites []
[2016-03-15 23:01:10,016][INFO ][node                     ] [Thor] initialized
[2016-03-15 23:01:10,017][INFO ][node                     ] [Thor] starting ...
[2016-03-15 23:01:10,106][INFO ][transport                ] [Thor] publish_address {localhost/127.0.0.1:9300}, bound_addresses {127.0.0.1:9300}
[2016-03-15 23:01:10,115][INFO ][discovery                ] [Thor]   elasticsearch/9PmYq5tXQcaPUPqDh4VTSQ
[2016-03-15 23:01:40,116][WARN ][discovery                ] [Thor] waited for 30s and no initial state was set by the discovery
[2016-03-15 23:01:40,155][INFO ][http                     ] [Thor] publish_address {localhost/127.0.0.1:9200}, bound_addresses {127.0.0.1:9200}
[2016-03-15 23:01:40,155][INFO ][node                     ] [Thor] started
[2016-03-15 23:54:40,863][DEBUG][action.admin.cluster.health] [Thor] no known master node, scheduling a retry
[2016-03-15 23:55:10,864][DEBUG][action.admin.cluster.health] [Thor] timed out while retrying [cluster:monitor/health] after failure (timeout [30s])
[2016-03-15 23:55:10,874][INFO ][rest.suppressed          ] /_cluster/health  Params: {pretty=}
MasterNotDiscoveredException[null]
    at org.elasticsearch.action.support.master.TransportMasterNodeAction$AsyncSingleAction$5.onTimeout(TransportMasterNodeAction.java:205)
    at org.elasticsearch.cluster.ClusterStateObserver$ObserverClusterStateListener.onTimeout(ClusterStateObserver.java:239)
    at org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:794)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745)
我在elasticsearch服务器之间打开了端口范围9200-9400,但日志似乎表明发现仍在超时。我设置了“discovery.ec2.tag.*”以加快发现过程,但这没有帮助


有人知道这个插件需要如何配置吗?我已经阅读了一些指南,使用了比我更少的配置选项,并且仍然能够将节点连接到主节点。

我正在运行ElasticSearch 2.2。以下是我的工作配置示例:

plugin.mandatory: cloud-aws
cluster.name: mynewcluster
cloud.aws.access_key: mykey
cloud.aws.secret_key: mysecret
cloud.aws.region: us-east-1
discovery.type: ec2
discovery.ec2.tag.elasticsearch: mynewcluster
我想你需要看看你的网络配置。特别是
network.host
。从:

默认情况下,Elasticsearch仅绑定到本地主机。这足以让您运行本地开发服务器(如果在同一台计算机上启动多个节点,甚至可以运行开发群集),但您需要配置一些基本网络设置,以便跨多台服务器运行真正的生产群集

我的elasticsearch.yml中没有
network.host
配置。这让我建议把它全部拿出来。但是,由于文档说它默认绑定到localhost,我还建议您尝试将其设置为节点的公共主机名或IP


所有这些都假设您根据以下内容正确设置了IAM、安全组:

,因此在es论坛中进行此聊天后:

我决定干净地重建节点,因为我怀疑Java从8降级到7以允许cloud aws插件工作可能是导致问题的原因,并且我尝试了许多失败的修复。我还(从提供的链接中的advise)安装了marvel代理和许可证插件,但我还没有看到其他人这样做以使discovery正常工作,因此我不确定这是否是一项要求。我还确保保持es软件包升级,因为当es升级时,惊奇漫画插件有点抱怨(尽管插件也可以升级,所以这只是个人喜好)


Discovery现在运行得很好。

谢谢。今晚我将看一看“network.host”。我的IAM小组有点不同。我还提供了‘ec2:DescribeTags’、‘ec2:DescribeInstances’、‘ec2:DescribeInstanceStatus’、‘ec2:DescribeAddresss’、‘ec2:AssociateAddress’、‘ec2:DisassociateAddress’、‘ec2:DescribeRegions’和‘ec2:DescribeAvailabilityZones’,因此我尝试删除‘network.host’并将其设置为内部ip节点,并获得“等待了30秒,发现未设置初始状态”。将“network.host”设置为公共ip时,我收到绑定异常“java.net.BindException:无法分配请求的地址”“致publicipaddress:9400您的配置还有其他内容吗?你能分享你的整个elasticsearch.yml吗?另外,你发布的配置看起来可能有一些拼写错误:
cloud:aws:access\u key:foobar cloud:aws:secret\u key:barfoo cloud:aws:region:eu-west-1发现:type:ec2
。请看冒号。另外,请看dadoonet的最终答案。看来他已经为使用2.1.0的人解决了一个类似的问题。
plugin.mandatory: cloud-aws
cluster.name: mynewcluster
cloud.aws.access_key: mykey
cloud.aws.secret_key: mysecret
cloud.aws.region: us-east-1
discovery.type: ec2
discovery.ec2.tag.elasticsearch: mynewcluster