您需要将文件配置/etc/kibana/kibana.yml
为 root:取消注释以下行:
服务器端口:5601
# Kibana is served by a back end server. This setting specifies the port to use.
server.port: 5601
服务器主机:“0.0.0.0”
# To allow connections from remote users, set this parameter to a non-loopback address.
server.host: "0.0.0.0"
弹性搜索.hosts
更改<your-elastic-server-ip>
为您的弹性搜索服务器 IP,例如192.168.1.XX
# The URLs of the Elasticsearch instances to use for all your queries.
elasticsearch.hosts: ["http://<your-elastic-server-ip>:9200"]
并检查防火墙上的端口:
$ sudo firewall-cmd --list-all
输出:
public (active)
target: default
icmp-block-inversion: no
interfaces: ens33
sources:
services: cockpit dhcpv6-client ftp ssh
ports: 10000/tcp 3306/tcp 9200/tcp 5601/tcp
protocols:
masquerade: no
forward-ports:
source-ports:
icmp-blocks:
rich rules:
如果您没有看到9200/tcp 5601/tcp端口打开,请使用 sudo 执行以下命令:
$ sudo firewall-cmd --zone=public --permanent --add-port 9200/tcp
$ sudo firewall-cmd --zone=public --permanent --add-port 5601/tcp