如何在elasticsearch中查看Logstash打到elasticsearch的数据

2025-03-22 23:32:31
推荐回答(2个)
回答1:

在output->elasticsearch下增加一个index配置
output {
elasticsearch {
hosts => ["ip:port"]
index => "test_system_log"
}
}
查看的的话,就装kibana好了,在kibana的settings->indices页面,在页面里面的输入框输入test_system_log,如果下面的按钮文字不是unable to fetch mapping xxxx,就说明日志收集成功了,点create按钮就创建好了

回答2:

  在output->elasticsearch下增加一个index配置
  output {
  elasticsearch {
  hosts => ["192.168.10.166:9200"]
  index => "test_system_log"
  }
  }

  查看的的话,就装kibana好了,在kibana的settings->indices页面,在页面里面的输入框输入test_system_log,如果下面的按钮文字不是unable to fetch mapping xxxx,就说明日志收集成功了,点create按钮就创建好了