Skip to content

This plugin for Icinga/Nagios is used to monitor a variety of a RHV and oVirt environement including datacenters, clusters, hosts, vms, vm pools and storage domains.

License

Notifications You must be signed in to change notification settings

rk-it-at/check_rhv

This branch is 35 commits ahead of ovido/check_rhev3:master.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

4046dff · Feb 15, 2022
Oct 19, 2018
Aug 11, 2021
Oct 19, 2018
Aug 27, 2012
Oct 19, 2018
Aug 27, 2012
Apr 12, 2018
Aug 27, 2012
Feb 15, 2022
Oct 19, 2018
Feb 21, 2014
Nov 24, 2021
Oct 19, 2018

Repository files navigation

Please note that this plugin isn't maintained any longer as I don't use oVirt/RHV anymore.


#*********************************************************#
#                                                         #
#     README for check_rhv plugin for Icinga/Nagios       #
#                                                         #
#*********************************************************#

What is check_rhv?
====================

This plugin for Icinga/Nagios is used to monitor a variety of
an RHEV or oVirt environement including datacenters, clusters, hosts,
vms, vm pools and storage domains.


Contributions / Help
====================

Send email to rkoch@rk-it.at if you have questions regarding use
of this software. Please include the following information in your email:
* OS type and version
* Perl version

To submit patches or suggest improvements, send email to rkoch@rk-it.at or create
a pull request on Github. Thanks.


Installation
============

The check_rhv installation can be used by following the standard autotools
installation process, documented in the INSTALL file. As a quick start you can do


NOTE: Deploy the dependencies below for the system version you have here, first
For RHEL 7/8 or Fedora 35 run in this order (cwd is the check_rhv repo path)
$ /usr/bin/aclocal
$ automake --add-missing
$ autoconf
$ ./configure
$ make all
$ sudo make install

For other systems, use the standard method of deploying
$ ./configure
$ make all
# make install

This will install check_rhv to /usr/local/nagios/libexec and the PNP template
to /usr/local/pnp4nagios/share/templates.

To change these paths use the following options:
--prefix=<path_to_nagios_plugins>
--with-pnp-dir=<path_to_pnp_share_folder>

If you don't use PNP you can disable installing the PNP template with:
--disable-pnp-template

To change the user and group ownership of these files use:
--with-nagios-user=<user>
--with-nagios-group=<group>

For example if you use Icinga and do not use PNP, you can use the following commands to configure your install for that:
$ ./configure --with-nagios-user=icinga --with-nagios-group=icinga --disable-pnp-template --prefix=/usr/lib64/nagios/plugins/


  General Options:
  ------------------------- -------------------------
               Nagios user: icinga
              Nagios group: icinga
         Plugins directory: /usr/lib64/nagios/plugins
             PNP directory: /usr/local/pnp4nagios/share
      Install PNP template: no


Review the options above for accuray. If they look okay,
type 'make all' to compile.

[icinga@vaulttest check_rhv]$ 


The 'nagios-plugins-rhv.spec' file demonstrates how to distribute check_rhv
as an RPM package.

Also make sure that the following requirements are met:
Perl
Perl-Modules:
  Crypt::SSLeay
  DateTime
  DateTime::Format::DateParse
  Getopt::Long
  HTTP::Request
  LWP
  LWP::Protocol:https
  LWP::UserAgent
  XML:Simple

For Fedora 19 (and newer) install the following packages:
# yum install perl-libwww-perl perl-LWP-Protocol-https perl-HTTP-Message \
              perl-XML-Simple

For RHEL 6 install the following packages:
# yum install perl-Crypt-SSLeay perl-libwww-perl perl-XML-Simple

For RHEL 7 install the following packages:
$ sudo yum install perl-LWP-Protocol-https openssl perl-DateTime-Format-DateParse.noarch perl-DateTime autoconf-archive.noarch automake libtool perl-libwww-perl autoconf perl-XML-Simple.noarch 

For Debian Squeeze install the following packages:
# apt-get install libwww-perl libcrypt-ssleay-perl libxml-simple-perl

For Fedora 35 or RHEL 8, install the following packages:
$ sudo dnf install perl-LWP-Protocol-https openssl perl-DateTime-Format-DateParse.noarch perl-DateTime autoconf-archive.noarch automake libtool perl-libwww-perl autoconf perl-XML-Simple.noarch

Documentation
=============

Short documentation on how to use this plugin.

Detailed documentation can be found on the project website
https://github.com/rk-it-at/check_rhv.

The following checks can be performed by this plugin:

Datacenter
----------
check_rhv -H rhevm -a admin@internal:password -D default
check_rhv -H rhevm -a admin@internal:password -D default -l status
check_rhv -H rhevm -a admin@internal:password -D default -l version
check_rhv -H rhevm -a admin@internal:password -D default -l storage
check_rhv -H rhevm -a admin@internal:password -D default -l storage -s status
check_rhv -H rhevm -a admin@internal:password -D default -l storage -s usage
check_rhv -H rhevm -a admin@internal:password -D default -l storage -s overall-usage

Cluster
-------
check_rhv -H rhevm -a admin@internal:password -C default
check_rhv -H rhevm -a admin@internal:password -C default -l hosts
check_rhv -H rhevm -a admin@internal:password -C default -l vms
check_rhv -H rhevm -a admin@internal:password -C default -l networks
check_rhv -H rhevm -a admin@internal:password -C default -l glustervolumes
check_rhv -H rhevm -a admin@internal:password -C default -l glusterbricks

Hosts
-----
check_rhv -H rhevm -a admin@internal:password -R rhevh
check_rhv -H rhevm -a admin@internal:password -R rhevh -l status
check_rhv -H rhevm -a admin@internal:password -R rhevh -l load
check_rhv -H rhevm -a admin@internal:password -R rhevh -l cpu
check_rhv -H rhevm -a admin@internal:password -R rhevh -l cpu -s usage
check_rhv -H rhevm -a admin@internal:password -R rhevh -l ksm
check_rhv -H rhevm -a admin@internal:password -R rhevh -l memory
check_rhv -H rhevm -a admin@internal:password -R rhevh -l memory -s mem
check_rhv -H rhevm -a admin@internal:password -R rhevh -l memory -s swap
check_rhv -H rhevm -a admin@internal:password -R rhevh -l network
check_rhv -H rhevm -a admin@internal:password -R rhevh -l network -s status
check_rhv -H rhevm -a admin@internal:password -R rhevh -l network -s traffic
check_rhv -H rhevm -a admin@internal:password -R rhevh -l network -s errors
check_rhv -H rhevm -a admin@internal:password -R rhevh -l updates

Storage
-------
check_rhv -H rhevm -a admin@internal:password -S storage
check_rhv -H rhevm -a admin@internal:password -S storage -l usage

VMs
---
check_rhv -H rhevm -a admin@internal:password -M vm
check_rhv -H rhevm -a admin@internal:password -M vm -l status
check_rhv -H rhevm -a admin@internal:password -M vm -l cpu
check_rhv -H rhevm -a admin@internal:password -M vm -l memory
check_rhv -H rhevm -a admin@internal:password -M vm -l network
check_rhv -H rhevm -a admin@internal:password -M vm -l network -s traffic
check_rhv -H rhevm -a admin@internal:password -M vm -l network -s errors

VM Pools
--------
check_rhv -H rhevm -a admin@internal:password -P pool
check_rhv -H rhevm -a admin@internal:password -P pool -l usage


Sample Icinga/Nagios definitions
--------------------------------

Detailed information can be found on the project website
https://github.com/ovido/check_rhv

Command
-------
define command{
  command_name check_rhv
  command_line $USER1$/check_rhv -H $_RHEVM$ -a $ARG1$ $ARG2$
}

Host
----
define host{
  use       linux-server
  host_name rhevh
  alias     RHEV Hypervisor
  address   192.168.1.2
  _rhevm    192.168.1.1
}

Service
-------
define service{
  use                 generic-service
  host_name           rhevh
  service_description RHEV CPU Check
  check_command       check_rhv!admin@internal:password!-R $HOSTNAME$ -l cpu
}

About

This plugin for Icinga/Nagios is used to monitor a variety of a RHV and oVirt environement including datacenters, clusters, hosts, vms, vm pools and storage domains.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Perl 85.5%
  • PHP 7.7%
  • Makefile 3.6%
  • M4 3.1%
  • Shell 0.1%