Kibana将无法连接到Elasticsearch在亚马逊的Elasticsearch服务亚马逊、连接到、Kibana、Elasticsearch

2023-09-11 12:02:46 作者:㈠世不弃づ

从主办我自己Elastiscsearch集群亚马逊Elasticsearch服务切换后,  我Kibana仪表板(版本4.0.2和4.1.2)将不会加载和我收到的kibana.log以下错误:

After switching from hosting my own Elastiscsearch cluster to Amazon's Elasticsearch Service, my Kibana dashboards (versions 4.0.2 and 4.1.2) won't load and I'm receiving the following error in kibana.log:

{
  "name": "Kibana",
  "hostname": "logs.example.co",
  "pid": 8037,
  "level": 60,
  "err": {
    "message": "Not Found",
    "name": "Error",
    "stack": "Error: Not Found\n    at respond (\/srv\/kibana\/kibana-4.1.2-linux-x64\/src\/node_modules\/elasticsearch\/src\/lib\/transport.js:235:15)\n    at checkRespForFailure (\/srv\/kibana\/kibana-4.1.2-linux-x64\/src\/node_modules\/elasticsearch\/src\/lib\/transport.js:203:7)\n    at HttpConnector.<anonymous> (\/srv\/kibana\/kibana-4.1.2-linux-x64\/src\/node_modules\/elasticsearch\/src\/lib\/connectors\/http.js:156:7)\n    at IncomingMessage.bound (\/srv\/kibana\/kibana-4.1.2-linux-x64\/src\/node_modules\/elasticsearch\/node_modules\/lodash-node\/modern\/internals\/baseBind.js:56:17)\n    at IncomingMessage.emit (events.js:117:20)\n    at _stream_readable.js:944:16\n    at process._tickCallback (node.js:442:13)"
  },
  "msg": "",
  "time": "2015-10-14T20:48:40.169Z",
  "v": 0
}

不幸的是,这个错误是不是非常有帮助。我认为这是一个包裹HTTP 404,但对于的什么的?

我如何可以连接Kibana安装到亚马逊的Elasticsearch服务?

How can I connect a Kibana install to Amazon's Elasticsearch Service?

推荐答案

这里有一些事情使用亚马逊的Elasticsearch服务时,要记住:

Here are a some things to keep in mind when using Amazon's Elasticsearch Service:

修改的访问策略采取的时间非确定性量。我发现它的好,至少等待15分钟后,状态不再是处理,使政策变化之后。

Modifications to the access policies take a non-deterministic amount of time. I've found that it's good to wait at least 15 minutes after the status is no longer "processing" after making policy changes.

它监听80端口的HTTP请求,而不是标准的端口9200。请确保您的 elasticsearch_url 配置指令反映了这一点,如:

It listens on port 80 for HTTP requests and not the standard port 9200. Be sure that your elasticsearch_url configuration directive reflects this, e.g.:

elasticsearch_url: http://es.example.co:80

elasticsearch_url: "http://es.example.co:80"

这很可能是你的Kibana实例将不会有必要的权限,以创建,它需要向您展示一个仪表板的指数 - 这是对问题的根源。退房指标上Elasticsearch域和寻找一个匹配 kibana_index config伪线(例如,通过的 http://es.example.co/_cat/indices )。

It's very likely that your Kibana instance will not have the necessary permissions to create the index that it needs to show you a dashboard -- this is towards the root of the issue. Check out the indexes on the Elasticsearch domain and look for a line that matches the kibana_index config directive (e.g. via http://es.example.co/_cat/indices).

例如,如果你的 kibana_index 指令是值 .kibana-4 ,如果你不看到如下一行:

for instance, if your kibana_index directive is the value is .kibana-4, if you don't see a line like the following:

green open .kibana-4           1 1      3 2  30.3kb  17.2kb

那么你的Kibana指数无法创建它所需要的指数。如果你去到仪表板的Elasticsearch服务于亚马逊和点击Kibana链接,它可能会创建一个 .kibana-4 索引你。

您可以在现有Kibana的配置指定该索引,你应该看到下一个点。

You can specify this index in your existing Kibana's configuration and you should see the next point.

您现有的Kibana安装可能会需要通过头认证:

Your existing Kibana install will likely require authentication via the header:

Kibana:Authorization头需要'凭证'参数。 Authorization头需要签名的参数。 Authorization头需要SignedHeaders'参数。 Authorization头要求的存在无论是X-AMZ-日期或日期标题。

Kibana: Authorization header requires 'Credential' parameter. Authorization header requires 'Signature' parameter. Authorization header requires 'SignedHeaders' parameter. Authorization header requires existence of either a 'X-Amz-Date' or a 'Date' header.

您可以在Kibana配置这一点,可以看到href="http://docs.aws.amazon.com/general/latest/gr/signing_aws_api_requests.html" rel="nofollow">签署API请求一般

 
精彩推荐