Search Exchange
Search All Sites
Nagios Live Webinars
Let our experts show you how Nagios can help your organization.Login
Directory Tree
check_kvm
1.0
2010-12-17
- Nagios 1.x
- Nagios 2.x
- Nagios 3.x
- Nagios XI 2009R1
- Nagios Fusion 2010R1
GPL
113712
File | Description |
---|---|
check_kvm | check_kvm |
Meet The New Nagios Core Services Platform
Built on over 25 years of monitoring experience, the Nagios Core Services Platform provides insightful monitoring dashboards, time-saving monitoring wizards, and unmatched ease of use. Use it for free indefinitely.
Monitoring Made Magically Better
- Nagios Core on Overdrive
- Powerful Monitoring Dashboards
- Time-Saving Configuration Wizards
- Open Source Powered Monitoring On Steroids
- And So Much More!
Qemu/Kvm Nagios Integration
Runs "virsh list" and returns the available vms.
Install: Put script in nagios client directory libexec/check_kvm
As a nagios nrpe plugin, add the following line to your client nrpe.cfg
command[virt_check_kvm]=/opt/nagios/libexec/check_kvm
No sudo is necessary if you simply add nagios user to the libvirt group
libvirtd:x:118:nagios
Runs "virsh list" and returns the available vms.
Install: Put script in nagios client directory libexec/check_kvm
As a nagios nrpe plugin, add the following line to your client nrpe.cfg
command[virt_check_kvm]=/opt/nagios/libexec/check_kvm
No sudo is necessary if you simply add nagios user to the libvirt group
libvirtd:x:118:nagios
Reviews (3)
bymac1959, June 14, 2017
You do not tell us how to install the plugin, YOu don't tell us if we install on the Nagios Server, the client or both. Are we suppose to edit the commands.cfg file. What is the command when we do get it working
define command {
command_name check_kvm or check_nrpe
command_line $USER1$/check_nrpe!virt_check_kvm -H $HOSTADDRESS$ -c $ARG1$
}
So what is it? Please explain this is a very very important plugin for me.
Thanks,
define command {
command_name check_kvm or check_nrpe
command_line $USER1$/check_nrpe!virt_check_kvm -H $HOSTADDRESS$ -c $ARG1$
}
So what is it? Please explain this is a very very important plugin for me.
Thanks,
I tried this on Fedora and Power servers. both works well.
number of running guests shows OK
number of Paused guests shows Warning
number of shutdown guests shows Critical
Disadvantage : user has no right to define the criticality.
number of running guests shows OK
number of Paused guests shows Warning
number of shutdown guests shows Critical
Disadvantage : user has no right to define the criticality.
The script works well, the only issues are with libvirt permissions, not with the script. I noticed that it truncated the "shut down" status to just "shut", so I tweaked the awk command from
{print $2":"$3}
to
{print $2":"$3" "$4}
This prints an extra space for one word commands, but I couldn't see a concise way to insert an conditional.
{print $2":"$3}
to
{print $2":"$3" "$4}
This prints an extra space for one word commands, but I couldn't see a concise way to insert an conditional.