[英]Custom Grok Pattern for [serverity]MMDD
I'm a beginner in writing grok
patterns and I'm unable to figure out how to write custom grok pattern for this我是编写
grok
模式的初学者,但我无法弄清楚如何为此编写自定义 grok 模式
I0224 22:37:20.377508 2437 zookeeper_watcher.cpp:326] Zk Session Disconnected, notifying watchers
I0224 22:37:20.377508 2437 zookeeper_watcher.cpp:326] Zk Session 断开连接,通知观察者
"I" being log_severity.
“我”是 log_severity。 and "0224" is in MMDD format.
“0224”是MMDD格式。
I've tried to work in https://grokdebug.herokuapp.com/ with the standard grok
patterns but I'm unable to seperate log_severity from month and day.我尝试使用标准的
grok
模式在https://grokdebug.herokuapp.com/中工作,但我无法将 log_severity 与月份和日期分开。
Really appreciate any help or directions.非常感谢任何帮助或指示。
Thanks!谢谢!
%{DATA:severity}%{MONTHNUM:month}%{MONTHDAY:day} %{TIME:timestamp}%{SPACE}%{INT:num}%{SPACE}%{GREEDYDATA:message}
This is what I've come up with after quite a bit of researching.这是我经过大量研究后得出的结论。 Hopefully it'll be useful for someone who's looking!
希望它对正在寻找的人有用!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.