Search Exchange
Search All Sites
Nagios Live Webinars
Let our experts show you how Nagios can help your organization.Login
Directory Tree
Solaris Zpools checker
This small plugin let you check the status of each ZFS disks pool configured on your server.
Reviews (3)
bydanieljdoughty, March 1, 2014
It checks all pools and only has a critical threshold not a warning threshold. But it works and that's a lot better than most checks out of the box.
byMckey, February 21, 2013
At this string of the script:
if [ ${exit_text} ]
insert the double quotes in this way:
if [ "${exit_text}" ]
That's useful if you have more then 2 zpools.
if [ ${exit_text} ]
insert the double quotes in this way:
if [ "${exit_text}" ]
That's useful if you have more then 2 zpools.
Hi,
plugin works on some non-global zones and not others.
ngz02c 39G 1.7M 39G 1% /apps
ngz02b 293G 168G 125G 58% /dm
ngz02a 68G 18G 51G 26% /dm_dump
/usr/local/nagios/libexec/check_zpools
exit_code=0
exit_text=
+ /usr/sbin/zpool list -Ho name
POOLS=ngz02a
ngz02b
ngz02c
+ [ ]
THRESHOLD=90
+ echo ngz02a ngz02b ngz02c
+ cut -d% -f1
+ /usr/sbin/zpool list -Ho capacity ngz02a
CAPACITY=25
+ /usr/sbin/zpool list -Ho health ngz02a
HEALTH=ONLINE
+ errors_checker ngz02a 25 ONLINE
+ [ ]
+ [ 25 -gt 90 -o ONLINE != ONLINE ]
exit_text=OK:ngz02a:25%:ONLINE
+ cut -d% -f1
+ /usr/sbin/zpool list -Ho capacity ngz02b
CAPACITY=56
+ /usr/sbin/zpool list -Ho health ngz02b
HEALTH=ONLINE
+ errors_checker ngz02b 56 ONLINE
+ [ OK:ngz02a:25%:ONLINE ]
+ [ 56 -gt 90 -o ONLINE != ONLINE ]
exit_text=OK:ngz02a:25%:ONLINE OK:ngz02b:56%:ONLINE
+ cut -d% -f1
+ /usr/sbin/zpool list -Ho capacity ngz02c
CAPACITY=0
+ /usr/sbin/zpool list -Ho health ngz02c
HEALTH=ONLINE
+ errors_checker ngz02c 0 ONLINE
+ [ OK:ngz02a:25%:ONLINE OK:ngz02b:56%:ONLINE ]
/usr/local/nagios/libexec/check_zpools: test: argument expected
plugin works on some non-global zones and not others.
ngz02c 39G 1.7M 39G 1% /apps
ngz02b 293G 168G 125G 58% /dm
ngz02a 68G 18G 51G 26% /dm_dump
/usr/local/nagios/libexec/check_zpools
exit_code=0
exit_text=
+ /usr/sbin/zpool list -Ho name
POOLS=ngz02a
ngz02b
ngz02c
+ [ ]
THRESHOLD=90
+ echo ngz02a ngz02b ngz02c
+ cut -d% -f1
+ /usr/sbin/zpool list -Ho capacity ngz02a
CAPACITY=25
+ /usr/sbin/zpool list -Ho health ngz02a
HEALTH=ONLINE
+ errors_checker ngz02a 25 ONLINE
+ [ ]
+ [ 25 -gt 90 -o ONLINE != ONLINE ]
exit_text=OK:ngz02a:25%:ONLINE
+ cut -d% -f1
+ /usr/sbin/zpool list -Ho capacity ngz02b
CAPACITY=56
+ /usr/sbin/zpool list -Ho health ngz02b
HEALTH=ONLINE
+ errors_checker ngz02b 56 ONLINE
+ [ OK:ngz02a:25%:ONLINE ]
+ [ 56 -gt 90 -o ONLINE != ONLINE ]
exit_text=OK:ngz02a:25%:ONLINE OK:ngz02b:56%:ONLINE
+ cut -d% -f1
+ /usr/sbin/zpool list -Ho capacity ngz02c
CAPACITY=0
+ /usr/sbin/zpool list -Ho health ngz02c
HEALTH=ONLINE
+ errors_checker ngz02c 0 ONLINE
+ [ OK:ngz02a:25%:ONLINE OK:ngz02b:56%:ONLINE ]
/usr/local/nagios/libexec/check_zpools: test: argument expected