Kibana、elasticsearch、filebeat开启x-pack监控教程

   现在很多团队都采用ELK的数据方案。具体的运转流程如下:

    

    这个流程比较长,需要监控内容比较多。

  •     filebeat出现异常造成数据丢失
  •     kafka造成异常
  •     es出现问题无法正常提供服务

目标

    通过安装x-pack实现对es和filebeat的监控。

教程

elasticsearch开启x-pack

1)安装x-pack

elasticsearch-plugin install x-pack

2)修改配置文件

elasticsearch.yml

#xpack
 
xpack.security.enabled: false
 
xpack.monitoring.enabled: true
 
xpack.graph.enabled: false
 
xpack.watcher.enabled: false
 
xpack.monitoring.exporters:
 
  id1:
 
    type: http
 
    host: ["http://elasticsearch-server-01:9200", "http://elasticsearch-server-02:9200", "http://elasticsearch-server-03:9200"]
 
    auth.username: remote_monitor
 
    auth.password: changeme

然后重启es服务

Kibana开启x-pack

1)安装x-pack

kibana-plugin install x-pack

2)修改配置文件

# x-pcak
 
xpack.security.enabled: false
 
xpack.monitoring.enabled: true
 
xpack.graph.enabled: false
 
xpack.reporting.enabled: false
 
xpack.monitoring.elasticsearch.url: "http://elasticsearch-server-01:9200"
 
xpack.monitoring.elasticsearch.username: "kibana-monitor"
 
xpack.monitoring.elasticsearch.password: "changeme"

重启kibana

filebeat开启x-pack

1)修改配置文件

#============================== Xpack Monitoring ===============================
 
xpack.monitoring.enabled: true
 
 
 
 
xpack.monitoring.elasticsearch:
 
  hosts: [ "http://elasticsearch-server-01:9200" ]
 
  username: "elastic"
 
  password: "changeme"

重启filebeat

 

你可能感兴趣的:(elasticsearch)