I have some issue when trying to replace some fields in NLS. Here an example of the log I try to parse :
Code: Select all
[Server:server-four] \u001b[0m\u001b[0m14:41:16,096 INFO [org.jboss.as.webservices] (ServerService Thread Pool -- 30) JBAS015537: Activating WebServices Extension\u001b[0m
Code: Select all
if [program] == 'console' {
grok {
match => [ 'message', '\[%{WORD}:%{USERNAME:server_name}\] (?:(\\u001b\[%{INT}m)+)%{TIME} %{LOGLEVEL:level} %{GREEDYDATA:msg}']
named_captures_only => true
}
mutate {
replace => [ 'type', '%{server_name}' ]
replace => [ 'severity_label', '%{level}']
}
}
The issue is that the mutate filter replace both 'type' and 'severity_label' fields with literally '%{server_name}' and '%{level}' and not the values (should be respectively 'server-four' and 'INFO').
I tried many different configuration and nothing works.
I hope somebody can help me with this. I'm pretty sure it's just a small missing in the configuration but I'm not able to find it.
Thanks in advance for your help.