【问题标题】:Kibana public IP site cannot be reached无法访问 Kibana 公网 IP 站点
【发布时间】:2017-09-14 01:34:24
【问题描述】:

无法从谷歌计算引擎获取 Kibana 的公共 IP。表示无法访问该站点,但如果我将 elasticsearch.ymllocalhost 更改为 0.0.0.0,则 Elasticsearch 通过公共 IP 工作。

关闭 nginx 只测试 Kibana。

运行于:Ubuntu 16.04、Elasticsearch 5.6.0、Kibana 5.6.0

port 5601 Kibana firewall screenshot 允许使用防火墙

kibana.yml 文件包含以下内容:

server.port: 5601
server.host: "0.0.0.0"
elasticsearch.url: "http://localhost:9200"
elasticsearch.ssl.verificationMode: none

运行netstat -natp | grep 5601,我得到:

(Not all processes could be identified, non-owned process info
 will not be shown, you would have to be root to see it all.)
tcp        0      0 0.0.0.0:5601            0.0.0.0:*               LISTEN      -  

运行sudo netstat -tupln 返回:

Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name    
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN      1916/sshd           
tcp        0      0 0.0.0.0:5601            0.0.0.0:*               LISTEN      10615/node          
tcp        0      0 0.0.0.0:5355            0.0.0.0:*               LISTEN      1447/systemd-resolv 
tcp6       0      0 127.0.0.1:9300          :::*                    LISTEN      8490/java           
tcp6       0      0 :::22                   :::*                    LISTEN      1916/sshd           
tcp6       0      0 :::5355                 :::*                    LISTEN      1447/systemd-resolv 
tcp6       0      0 127.0.0.1:9200          :::*                    LISTEN      8490/java           
udp        0      0 127.0.0.53:53           0.0.0.0:*                           1447/systemd-resolv 
udp        0      0 0.0.0.0:68              0.0.0.0:*                           1156/dhclient       
udp        0      0 10.128.0.100:123        0.0.0.0:*                           1702/ntpd           
udp        0      0 127.0.0.1:123           0.0.0.0:*                           1702/ntpd           
udp        0      0 0.0.0.0:123             0.0.0.0:*                           1702/ntpd           
udp        0      0 0.0.0.0:5355            0.0.0.0:*                           1447/systemd-resolv 
udp6       0      0 fe80::4001:aff:fe80:123 :::*                                1702/ntpd           
udp6       0      0 ::1:123                 :::*                                1702/ntpd           
udp6       0      0 :::123                  :::*                                1702/ntpd           
udp6       0      0 :::5355                 :::*                                1447/systemd-resolv 

curl -i localhost:5601 返回:

HTTP/1.1 200 OK
kbn-name: kibana
kbn-version: 5.6.0
cache-control: no-cache
content-type: text/html; charset=utf-8
content-length: 217
accept-ranges: bytes
Date: Mon, 11 Sep 2017 23:27:38 GMT
Connection: keep-alive
<script>var hashRoute = '/app/kibana';
var defaultRoute = '/app/kibana';
var hash = window.location.hash;
if (hash.length) {
  window.location = hashRoute + hash;
} else {
  window.location = defaultRoute;

sudo systemctl status kibana 表示 kibana 服务处于活动状态并正在运行

似乎端口 5601 不适用于 Google Compute Engine 中的任何实例,任何想法都将不胜感激。

【问题讨论】:

  • 你试过在kibana.yml的server.host设置中设置Kibana的公网IP吗?
  • 试过了,还是不行

标签: elasticsearch kibana gcloud google-compute-engine


【解决方案1】:

为端口 5601 制定新的单独防火墙规则解决了这个问题!谢谢大家的意见

【讨论】:

  • 第二天来了又停止工作,重新创建5601端口也没用...
猜你喜欢
  • 2021-08-10
  • 1970-01-01
  • 2012-05-02
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2018-07-29
  • 2013-10-04
相关资源
最近更新 更多