I need to drop logs when syslog5424_host is e.g dev.dev.sample-app-109, the number at the end will change but I have regex to accommodate that. This is my current configuration but it's not dropping the logs.
The field syslog5424_host looks something like this: dev.dev.sample-app-206, dev.dev.sample-app-206, dev.dev.sample-app-206
filter {
if [syslog5424_host] =~ /(dev\.dev\.sample-app-[0-9]{1,10},?\s?)+/ {
mutate {
add_tag => ["SampleApp"]
}
}
if "SampleApp" in [tags] {
drop { }
}
}
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.