grok_exporter icon indicating copy to clipboard operation
grok_exporter copied to clipboard

Show or log unmatched lines

Open jerrykan opened this issue 5 years ago • 2 comments
trafficstars

It would be useful when trying to set up a new configuration to find out which files are not being matched and either display them to stdout or log them to a file. This would make it much easier to determine if any important log entries are being missed or not parsed properly.

This is probably not something that everyone would want to run in production, so I assume adding a new command-line option to enable this sort of feature would be needed.

jerrykan avatar Apr 16 '20 07:04 jerrykan

Thanks for the suggestion. Could you create an example how the console output should look like from your perspective?

fstab avatar Apr 16 '20 20:04 fstab

Personally I would be happy if the unmatched log lines were just printed to stdout verbatim. So far I haven't seen grok_exporter provide any output - so there doesn't seem to be any existing output that would be confused for log entries from a log file.

It might be desirable to add some sort of prefix when the log line is output, but some lines (ie. exim) tend to be pretty lengthy already, so adding prefixes might things even more unwieldy.

jerrykan avatar Apr 17 '20 02:04 jerrykan