Monitoring plugin for Apache with mod_watch module
Collects request and document counts.
Plugin supports Nagios, Collectd and Influx Line Protocol output formats.
Requirements:
-
Perl interpreter
-
mod_watch module (patches for Apache 2.4 can be found here)
Example Apache config
LoadModule watch_module libexec/apache24/mod_watch.so
<VirtualHost 127.0.0.1:8080>
<Location /watch-list>
SetHandler watch-list
</Location>
</VirtualHost>
Collectd output format requires this line in types.db file:
apache docs:GAUGE:0:U, reqs:GAUGE:0:U
Plugin parameters
<watch-list url>
[Required] watch-list URL, e.g. http://login:pass@127.0.0.1:8080/watch-list?auto
<domain.com,example.org,...>
[Required] Comma-separated list of domains to monitor (used as type-instances for collectd and as "domain" tag for influxlp)
<collectd|influxlp>
[Optional] Output format - nagios, collectd, influxlp (defaults to nagios)
<u>Collectd format:</u>
<myhost.com>
[Optional] Hostname (defaults to current system hostname)
<myplugin>
[Optional] Plugin name (defaults to apachewatch)
<300>
[Optional] Interval (defaults to 60 sec)
<u>Influx Line-Protocol format:</u>
<mymeasurement>
[Optional] Measurement name (defaults to apachewatch)