VIRTSNMP: SNMP agent for monitoring hypervisor and virtual machines

The VIRTSNMP is an implementation of SNMP agent using net-snmp and libvirt to monitor virtual machines controlled by a hypervisor. This software supports hypervisors that are supported by libvirt; e.g., Xen and KVM. This software is launched as a sub-agent of net-snmp (snmpd) on a hypervisor.

The MIB objects managed by this agent is compliant with Internet-Draft: draft-asai-vmm-mib-05.

Search from the Internet:
Custom Search

VIRTSNMP

The software (version 0.3.0a) is available at virtsnmpd-0.3.0a.tar.gz. The detailed manual and technical documents will be provided in future. If you have any comments on this software, please let us <bug __at__ scyphus.co.jp> (please replace "__at__" with "@") know.

License

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY AUTHORS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL AUTHORS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

The views and conclusions contained in the software and documentation are those of the authors and should not be interpreted as representing official policies, either expressed or implied, of Scyphus Solutions Co. Ltd.

How to use it

In this example, port TCP/1705 is used for the agentX protocol to communicate between master agent (snmpd) and our sub-agent (virtsnmpd) within localhost. The database file that maintains the list of virtual machines to enable consistent indexing is specified as /path/to/uuid.db.

First, edit the configuration file for the master agent (snmpd) /etc/snmpd.conf, for example:

rocommunity public
rocommunity6 public
agentaddress udp:163,udp6:163

Second, launch snmpd of net-snmp, for example with the following command:

# snmpd -C -c /etc/snmpd/snmpd.conf --master=agentx --agentXSocket=tcp:localhost:1705

Note that --master option specifies the protocol to communicate with sub-agent (i.e., agentX in this example), and --agentXSocket option specifies the transport protocol, bind address, and port number for agentX protocol.

Then, launch the sub-agent, for example with the following command:

# virtsnmpd -u /path/to/uuid.db -x tcp:localhost:1705

Tested environments