filebeat配置文件:

filebeat.inputs:

- type: log
  enabled: true
  paths:
    - /opt/hkd-cloud/hkd-custom/hkd-custom.out
  fields: 
    log_source: test_custom
  fields_under_root: true

logstash输出到es

output {

    elasticsearch {
      hosts => ["http://172.17.107.187:9203", "http://172.17.107.187:9201","http://172.17.107.187:9202"]
      index => "filebeat_%{[log_source]}-%{+YYYY.MM.dd}"
      user => "elastic"
      password => "escluter123456"
    }

}

注意:index索引这儿需要加上中括号[]

相关文章:

  • 2022-12-23
  • 2021-07-18
  • 2021-12-02
  • 2022-12-23
  • 2022-12-23
  • 2022-01-26
  • 2022-01-15
  • 2022-12-23
猜你喜欢
  • 2021-10-08
  • 2022-12-23
  • 2021-06-22
  • 2021-06-20
  • 2021-06-18
  • 2021-05-29
  • 2022-01-01
相关资源
相似解决方案