You are here
Varnish Cache Opspack
Varnish Cache is a HTTP accelerator designed for dynamic, content-heavy web sites as well as heavily consumed APIs. You can install it in front of any server that speaks HTTP and configure it to cache the contents. It typically speeds up delivery with a factor of 300 - 1000x, depending on your architecture. In addition to its performance, one of the key features of Varnish Cache is the flexibility of VCL (its configuration language). VCL enables you to write policies on how incoming requests should be handled.
What You Can Monitor
Our Varnish Cache Opspack allows you to pull vital information from your environment including connection information, number of sessions/client requests, thread statistics and much more.
This Opspack has been tested and configured against Varnish Cache 4.0 and 5.0 (See https://github.com/opsview/application-varnish-cache-3.0 for version 3.0)
Setup and Configuration
On the Varnish Cache box
To add the Varnish Cache plugin to your Opsview agent.
First, you need to add the plugin to the correct file directory at /usr/local/nagios/libexec/, which is the default location of the installed Opsview plugins.
Next, give the plugin execution rights by running the command
chmod u+x check_varnish. The plugin also needs to be owned by the Nagios user and group, which can be changed by running the command
chown nagios:nagios check_varnish.
Next add the plugin details to the configuration by adding the line
to the nrpe.cfg file located at /usr/local/nagios/etc/.
Restart the Opsview plugin with the command service opsview-agent restart.
Allow access to the Varnish stats by running the command
chmod a+x /var/lib/varnish/_.vsm, if the _.vsm file is in the default location and if this file doesn't have execution access already, this will allow the agent access to the commands it needs.
On the Opsview master
To configure and utilize this Opspack, you need to add the 'Application - Varnish Cache' Opspack to the host running the Varnish Cache software
Step 1: Add the host template
Step 2: If you are running multiple instances of Varnish Cache, you can add the variable VARNISHCACHE_INSTANCE and give the name of the Varnish instance.
For every instance you will have to create a new host and add the VARNISHCACHE_INSTANCE variable.
Step 3: Reload and view the Varnish Cache statistics
ODI-1154 Release Opspacks for Opsview Monitor 6.0
Initial release of Opspack to work with Opsview Monitor 6.0
ODI-604 Release Opspacks to GitHub
Initial upload of existing Opspacks to GitHub