Nagios : How to Monitoing LVM Free Space in Linux
Once you have installed and configured nagios-client in your Linux system you can easily monitor your LVM on Nagios tool. This LVM space monitoring only for low disk space.
Download the files from the URL : http://www.lihas.de/anleitungen-und-service/check_vg_size
Move the file to that directory,
To run the file give execute permission and nagios user permission,
Now, you can check your volume group free space,
-w specified to Warning Status
-c specified to Critical Status
VG vg0 OK Free Space 2230 GB gross
The above command pointing to warning and critical free disk space status.
If the script is functional, open your nagios nrpe.cfg file and add the below line into it.
command[check_vg_size]=/usr/local/nagios/libexec/check_vg_size -w 500 -c 300 -v vg0
On Nagios Server :
Open client configuration file and define the service,
service_description LVM SPACE
Save and execute below command to check the configuration whether is it right?
output should be :
Total Warnings: 0
Total Errors: 0
Things look okay - No serious problems were detected during the pre-flight check
Finally, Restart the nagios server :
Running configuration check...done.
Stopping nagios: done.
Starting nagios: done.