diff --git a/plugins/all/all.go b/plugins/all/all.go index b510d2521..3c4155c38 100644 --- a/plugins/all/all.go +++ b/plugins/all/all.go @@ -23,4 +23,5 @@ import ( _ "github.com/influxdb/telegraf/plugins/redis" _ "github.com/influxdb/telegraf/plugins/rethinkdb" _ "github.com/influxdb/telegraf/plugins/system" + _ "github.com/influxdb/telegraf/plugins/webservercodes" ) diff --git a/plugins/webservercodes/README.md b/plugins/webservercodes/README.md new file mode 100644 index 000000000..1a609b1c5 --- /dev/null +++ b/plugins/webservercodes/README.md @@ -0,0 +1,52 @@ +A plugin that collects and counts http codes from any webserver that has access log. +It parses last several entries of log files and counts http codes. + +Configuration. + +A plugin supports per-virtualhost configuration. Config may contains one or more of this sections (example): + +[[webservercodes.vhosts]] + +host = "defaulthost" + +access_log = "/var/log/apache2/access.log" + +regex_parsestring = `\[(?P