filebeat+logstash配置搭建


声明:本文转载自https://my.oschina.net/openplus/blog/1584861,转载目的在于传递更多信息,仅供学习交流之用。如有侵权行为,请联系我,我会及时删除。

基于ELK日志分析系统搭建 v6.0.0 做filebeat配置。

版本:filebeat-6.0.0、logstash-6.0.0、elasticsearch-6.0.0、kibana-6.0.0

修改filebeat.yml 文件

# 启用  enabled: true # 设置日志文件路径   paths:     - /data/test2.log #-------------------------- Elasticsearch output ------------------------------ #关闭默认开启的elasticsearch配置 #output.elasticsearch:   # Array of hosts to connect to.   # hosts: ["localhost:9200"] #----------------------------- Logstash output -------------------------------- #开启logstash配置 output.logstash:   # The Logstash hosts    hosts: ["192.168.13.245:9022"] 
  • 创建filebeat、logstash、elasticsearch关联启动文件。
vi first-9an.conf # 指定输入数据源为beats 并且开发9011端口接受数据 input {     beats {         host => "192.168.13.245"         port => 9022     } } # 制定数据输出源为elasticsearch 并且指定index名称 output {     elasticsearch {         hosts => [ "192.168.13.245:9200" ]         index => "first-9an--%{+YYYY.MM.dd}"     } } 

启动logstash

/usr/local/logstash-6.0.0/bin/logstash -f /ELK/first-9an.conf 

启动filebeat

[root@ELK20171129 filebeat-6.0.0-linux-x86_64]# ./filebeat -e -c filebeat.yml 

启动kibana

[root@ELK20171129 ELK]# nohup /usr/local/kibana-6.0.0-linux-x86_64/bin/kibana > /ELK/logs/kibana.log 2>&1 &

访问kibana创建索引

本文发表于2017年12月05日 12:33
(c)注:本文转载自https://my.oschina.net/openplus/blog/1584861,转载目的在于传递更多信息,并不代表本网赞同其观点和对其真实性负责。如有侵权行为,请联系我们,我们会及时删除.

阅读 2201 讨论 0 喜欢 0

抢先体验

扫码体验
趣味小程序
文字表情生成器

闪念胶囊

你要过得好哇,这样我才能恨你啊,你要是过得不好,我都不知道该恨你还是拥抱你啊。

直抵黄龙府,与诸君痛饮尔。

那时陪伴我的人啊,你们如今在何方。

不出意外的话,我们再也不会见了,祝你前程似锦。

这世界真好,吃野东西也要留出这条命来看看

快捷链接
网站地图
提交友链
Copyright © 2016 - 2021 Cion.
All Rights Reserved.
京ICP备2021004668号-1