关于ELK:Centos6搭建ELK-02-安装使用Filebeat和Logstash

45次阅读

共计 698 个字符,预计需要花费 2 分钟才能阅读完成。

装置 Filebeat

官网文档:https://www.elastic.co/guide/…

curl -L -O https://artifacts.elastic.co/downloads/beats/filebeat/filebeat-7.13.3-x86_64.rpm
sudo rpm -vi filebeat-7.13.3-x86_64.rpm

配置文件门路

vim /etc/filebeat/filebeat.yml 

filebeat.config.modules:
  path: ${path.config}/modules.d/*.yml
装置 Logstash

官网文档:https://www.elastic.co/cn/dow…

vim /etc/yum.repos.d/logstash.repo

[logstash-7.x]
name=Elastic repository for 7.x packages
baseurl=https://artifacts.elastic.co/packages/7.x/yum
gpgcheck=1
gpgkey=https://artifacts.elastic.co/GPG-KEY-elasticsearch
enabled=1
autorefresh=1
type=rpm-md

装置

sudo yum install logstash
rpm -ql logstash #查看装置目录
ln -s /usr/share/logstash/bin/logstash /bin/ #创立软链接 

测试

logstash -e 'input {stdin {} } output {stdout {} }' #运行胜利后输出任意内容测试 

正文完
 0