filebeat.inputs:
- type: log
enable: true
paths:
- /var/log/nginx/access.log
output.elasticsearch:
hosts: ["10.0.0.51:9200"]
[root@web01 ~]# systemctl restart filebeat.service
#验证
[root@web01 ~]# ps -ef | grep filebeat
#访问Nginx
http://10.0.0.7:8081/
#查看ES页面
原文:https://www.cnblogs.com/Applogize/p/13545816.html