Kibana 连接elasticsearch失败

elasticsearch 版本:1.4.2
kibana 版本:3.1.2

按照http://stackoverflow.com/questions/26828099/kibana-returns-connection-...

添加了

http.cors.allow-origin: "/.*/"
http.cors.enabled: true

仍然无用,nginx给kibana加了

add_header Access-Control-Allow-Origin '*';

仍然提示

XMLHttpRequest cannot load http://10.0.10.221:9200/_nodes. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://kibana.dev.com' is therefore not allowed access.

直接访问http://10.0.10.221:9200/_nodes ok

现在不知道哪里出了问题

阅读 11.7k
2 个回答
新手上路,请多包涵

国外大神的回答,亲测可用,你试试:
If you are using elasticsearch-1.4 with Kibana-3 then add following parameters in elasticsearch.yml filehttp.cors.allow-origin: "/.*/"
http.cors.enabled: true
还有,据说kibana4解决了这个问题。

撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进