RedHatInsights / insights-core

Insights Core is a data collection and processing framework used by Red Hat Insights
https://cloud.redhat.com/insights
Apache License 2.0
151 stars 177 forks source link

No method to check whether /var/log/message is empty or not #2550

Open code-with-amitk opened 4 years ago

code-with-amitk commented 4 years ago

docstring example does not show any method to check if /var/log/message file has size=0, KCS for which this would be required.

bfahr commented 4 years ago

@amitkumar50 The current implementation for the /var/log/messages parser would not be able to provide this because the contents of that file is filtered when it is collected. Even though the messages file may contain lines on the system, if no filters match, there will be no data in the parser.

If you need to know whether /var/log/messages is empty, then a new spec and parser would be required to check the size of that file.