ELK记录
Filebeat
1 | ./filebeat -e -c filebeat.yml -d "publish" |
https://www.elastic.co/guide/en/beats/filebeat/7.8/filebeat-starting.html
Logstash
1 | ./logstash -f ../config/logstash-sample.conf --config.reload.automatic |
https://www.elastic.co/guide/en/logstash/current/advanced-pipeline.html
格式
1 | 2020-07-21 09:15:38,001 INFO [quartzScheduler_Worker-3] c.g.j.modules.quartz.jobs.SampleJob [SampleJob.java : 20] 定时任务! 时间:2020-07-21 09:15:38 |
elasticsearch
查看索引信息
curl -XGET 'http://localhost:9200/_cluster/health?pretty=true'
查看所有索引状态
curl 'localhost:9200/_cat/indices?v'
删除索引
curl -XDELETE http://localhost:9200/index_namee
nohup ./kibana >/dev/null 2>&1 &
nohup ./elasticsearch >/dev/null 2>&1 &
nohup ./logstash -f ../config/logstash-sample.conf --config.reload.automatic >/dev/null 2>&1 &