我的日志文件包含来自不同进程在同一文件上写入数据的数据。日志文件如下所示。
我正在写写 Grok 过滤器模式来提取不同的数据并在 Kibana 板中使用它。我尝试了一种模式,但它只适用于日志文件中的一行,它不适用于整个日志文件。
%{UUID:uuid} > %{WORD:level}:%{INT:LOGlevel} %{WORD:RClevel}: %{INT:RClevel} %{WORD:LOGtype} :%{GREEDYDATA:message}
我需要来自日志的 MGMT_RDCIP_INFO、PCI、DP_DRIVER 数据,例如 RATIO、QUALITY、Ceiling 数据。谁能指导我如何从日志中获取特定的关键字数据。
ef22119900-99ecf-10e9-7dfc-ffe0ea066dfff > LVL:3 CT: 0 MGMT_RDCIP_INFO :Bandwidth Management for Server: Ceiling = 112500.000000, Floor = 12500.000000, Active = 14825.552639
ef22119900-99ecf-10e9-7dfc-ffe0ea066dfff > LVL:3 CT: 0 PCI :Display 0 codec 0 (H264 Encoder) frames encoded per second : 11.56
ef22119900-99ecf-10e9-7dfc-ffe0ea066dfff > LVL:3 CT: 0 PCI :Display 1 codec 0 (H264 Encoder) frames encoded per second : 25.92
ef22119900-99ecf-10e9-7dfc-ffe0ea066dfff > LVL:3 CT: 0 PCI :QUALITY: 81.3918 81.3918 0.0 0.0
ef22119900-99ecf-10e9-7dfc-ffe0ea066dfff > LVL:3 CT: 0 PCI :RATIO: 5.73013 94.2699 0.0 0.0
ef22119900-99ecf-10e9-7dfc-ffe0ea066dfff > LVL:3 CT: 0 DP_DRIVER :Display duplication output id: 1 move MPPS 0.00, dirty MPPS 162.59, total MPPS 162.59```
[![snaphot of log file][1]][1]
[1]: https://i.stack.imgur.com/wuFum.jpg