output{
if "masternode" in [tags] {
if [type] == "ambari" {
elasticsearch {
hosts => ["endpoint"]
action => "index"
index => "ambarinodelog"
}
}
if [type] == "zookeeper" {
elasticsearch {
hosts => ["endpoint"]
action => "index"
index => "zookeeperlog"
}
}
}
if "masternode" in [tags] {
if [type] == "hive" {
elasticsearch {
hosts => ["endpoint"]
action => "index"
index => "hivelog"
}
}
if [type] == "zookeeper" {
elasticsearch {
hosts => ["endpoint"]
action => "index"
index => "zookeeperlog"
}
}
}
}
what i was trying to was
i have multiple filebeats with different tags.
want to send all zookeeper logs to single index irrespective of tags does it works?
If yes please guide me proper required changes in my configuration
If you want all Zookeeper logs sent to the same place regardless of tag, don't put your zookeeperlogs outputs inside any if "whatever" in [tags] conditionals.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.