A plugin for nagios to check the state of virtual servers on an LTM as well as creating Performance Data output on the amount of connections to each Virtual Server. The plugin is written in PHP and uses SNMP to gather the statuses of each Virtual Server. The plugin currently only supports SNMPv2 and has been tested on Big-IP 10.2 only but should work with other version of Big-IP.

You can get the plugin from here:

https://github.com/thomasweaver/check_ltm_vs

Help

This performs an SNMP lookup against an LTM and then check all Virtual Servers are OK and outputs current client connections as nagios PerfData

Required Values:

	-H Host address

	-C SNMP Community string
 
Optional Values:

	-t Timeout. Number of microseconds until first timeout

	-r Number of retries

	-e Exceptions. Value is a comma sperated string of exceptions not to check.

	-d Disabled Exceptions. Don't check whether the provided virtual servers are disabled. Comma Seperated
 
./check_ltm_vs.php -H IPADDRESS -c COMMUNITYSTRING -e vs_virtualserver1,vs_virtualserver2 -d vs_virtualserver1,vs_virtualserver2

Example

./check_ltm_vs.php -H 192.168.0.1 -C public -d virtualserver1,virtualserver2 -e virtualserver3,virtualserver4 -r 2

The example above will check virtual servers on 192.168.0.1 using Community String public. But will exclude virtualserver3 and virtualserver4 from any checks. It will not check whether virtual servers virtualserver1 and virtualserver2 are enabled but will check that there health state is ok. It will also only try and contact the LTM twice.

The plugin outputs performance data of the virtual servers it checks example out is below:

OK : 4 Virtual Servers OK | virtualserver1=98;;; virtualserver2=23;;; virtualserver3=10;;; virtualserver4;;;

Example of a check where the health state of a virtual server is unknown:

WARNING : virtualserver1, 90 Virtual Servers OK