I want to monitor an apache server. Primary goal is to detect if MaxClients gets reached, but later other values, too.
I looked at the nagios plugins, but most plugins seem to parse the HTML of the status page. I think this is an ugly solution. Is there any better way to get the server status?
Log file checking is not part of this question.
Answer
You don't need to parse HTML - Apaches mod_status is capable of producing output well-suitable for regex parsing when called with the ?auto
parameter (i.e. http://your-server/server-status/?auto
). Depending on what monitoring system you need this to work with, there may or may not be a working / well-tested collector for this kind of thing.
As an example, take a look at how it is done in OpenNMS: https://wiki.opennms.org/wiki/Monitoring_Apache_with_the_HTTP_collector
No comments:
Post a Comment