10.16. Monitoring Virtuozzo Objects via SNMP

You can monitor Virtuozzo objects via the Simple Network Management Protocol (SNMP). The implementation conforms to the same Structure of Management Information (SMI) rules as the data in the standard SNMP context: all objects are organized in a tree; each object identifier (OID) is a series of integers corresponding to tree nodes and separated by dots.

General information:

  • The OID of the root subtree with all the objects you can monitor is 1.3.6.1.4.1.26171.1.1.
  • The PARALLELS-RMOND-SMI.txt information base file is required to monitor the objects. Its default location is /usr/share/snmp/mibs.

The following subsections describe ways to enable and use SNMP to monitor cluster objects.

10.16.1. Enabling SNMP Access

To enable SNMP access on a hardware node, do the following:

  1. Install the rmond package.

    # yum install rmond
    
  2. If you have a Virtuozzo Storage cluster, add the following lines to the /etc/snmp/snmpd.local.conf file:

    rwcommunity parallels 127.0.0.1 .1.3.6.1.4.1.26171
    rwcommunity parallels <IP_network/subnet_mask> .1.3.6.1.4.1.26171
    

    Where <IP_network> is the Virtuozzo Storage cluster network and <subnet_mask> covers all the nodes participating in the cluster.

  3. Make sure the snmpd service is running.

10.16.2. Accessing Virtuozzo Objects via SNMP

You can access Virtuozzo objects with SNMP tools of your choice, e.g., the free Net-SNMP suite for Linux. For example, to display information on the node, do as follows:

  1. Install the net-snmp-utils package:

    # yum install net-snmp-utils
    
  2. Run the following snmpwalk command:

    # snmpwalk -m /usr/share/snmp/mibs/PARALLELS-RMOND-SMI.txt -c public -v2c 127.0.0.1 .1.3.6.1.4.1.26171.1.1
    

Typical output may be the following:

PARALLELS-RMOND-SMI::rmondVeId."{b5f09b02-7358-4998-860c-c622653859f3}" = STRING: \
{b5f09b02-7358-4998-860c-c622653859f3}
PARALLELS-RMOND-SMI::rmondVeName."{b5f09b02-7358-4998-860c-c622653859f3}" = STRING: centos
PARALLELS-RMOND-SMI::rmondVeState."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: \
running(805306372)
PARALLELS-RMOND-SMI::rmondVePerfectNode."{b5f09b02-7358-4998-860c-c622653859f3}" = STRING:
PARALLELS-RMOND-SMI::rmondVeMemoryTotal."{b5f09b02-7358-4998-860c-c622653859f3}" = Counter64: \
2147483648
PARALLELS-RMOND-SMI::rmondVeMemoryUsage."{b5f09b02-7358-4998-860c-c622653859f3}" = Counter64: \
1788
PARALLELS-RMOND-SMI::rmondVeSwapTotal."{b5f09b02-7358-4998-860c-c622653859f3}" = Counter64: 0
PARALLELS-RMOND-SMI::rmondVeSwapUsage."{b5f09b02-7358-4998-860c-c622653859f3}" = Counter64: 0
PARALLELS-RMOND-SMI::rmondVeCpuNumber."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: 2
PARALLELS-RMOND-SMI::rmondVeCpuLimit."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: 0
PARALLELS-RMOND-SMI::rmondVeCpuUnits."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: 0
PARALLELS-RMOND-SMI::rmondVeCpuSystem."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: 0
PARALLELS-RMOND-SMI::rmondVeCpuUser."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: 0
PARALLELS-RMOND-SMI::rmondVeType."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: vm(0)
PARALLELS-RMOND-SMI::rmondVeUuid."{b5f09b02-7358-4998-860c-c622653859f3}" = STRING: \
{b5f09b02-7358-4998-860c-c622653859f3}
PARALLELS-RMOND-SMI::rmondVeDiskName."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = STRING: /vz/vmprivate/b5f09b02-7358-4998-860c-c622653859f3/harddisk.hdd
PARALLELS-RMOND-SMI::rmondVeDiskTotal."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter64: 0
PARALLELS-RMOND-SMI::rmondVeDiskUsage."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter64: 0
PARALLELS-RMOND-SMI::rmondVeDiskReadRequests."{b5f09b02-7358-4998-860c-c622653859f3}".\
2881840264.645796544 = Counter64: 2
PARALLELS-RMOND-SMI::rmondVeDiskWriteRequests."{b5f09b02-7358-4998-860c-c622653859f3}".\
2881840264.645796544 = Counter64: 16714
PARALLELS-RMOND-SMI::rmondVeDiskReadBytes."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter64: 77824
PARALLELS-RMOND-SMI::rmondVeDiskWriteBytes."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter64: 1073883648
PARALLELS-RMOND-SMI::rmondVeDiskHash1."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter32: 2881840264
PARALLELS-RMOND-SMI::rmondVeDiskHash2."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter32: 645796544
PARALLELS-RMOND-SMI::rmondVeNetworkInterface."{b5f09b02-7358-4998-860c-c622653859f3}"."" = STRING:
PARALLELS-RMOND-SMI::rmondVeNetworkInBytes."{b5f09b02-7358-4998-860c-c622653859f3}"."" = \
Counter64: 6743089
PARALLELS-RMOND-SMI::rmondVeNetworkOutBytes."{b5f09b02-7358-4998-860c-c622653859f3}"."" = \
Counter64: 12472
PARALLELS-RMOND-SMI::rmondVeNetworkInPackets."{b5f09b02-7358-4998-860c-c622653859f3}"."" = \
Counter64: 33658
PARALLELS-RMOND-SMI::rmondVeNetworkOutPackets."{b5f09b02-7358-4998-860c-c622653859f3}"."" = \
Counter64: 159
PARALLELS-RMOND-SMI::rmondVeNetworkMacAddress."{b5f09b02-7358-4998-860c-c622653859f3}"."" = \
STRING: 001C42C329B0
PARALLELS-RMOND-SMI::rmondVeVCpuOrdinal."{b5f09b02-7358-4998-860c-c622653859f3}".0 = INTEGER: 0
PARALLELS-RMOND-SMI::rmondVeVCpuOrdinal."{b5f09b02-7358-4998-860c-c622653859f3}".1 = INTEGER: 1
PARALLELS-RMOND-SMI::rmondVeVCpuTime."{b5f09b02-7358-4998-860c-c622653859f3}".0 = Counter64: \
59720000000
PARALLELS-RMOND-SMI::rmondVeVCpuTime."{b5f09b02-7358-4998-860c-c622653859f3}".1 = Counter64: \
26720000000
PARALLELS-RMOND-SMI::rmondLocalVeNumber.0 = INTEGER: 1
PARALLELS-RMOND-SMI::rmondVeLimit.0 = INTEGER: 65535
PARALLELS-RMOND-SMI::rmondLicenseVeNumber.0 = INTEGER: 65535
PARALLELS-RMOND-SMI::rmondLicenseCtNumber.0 = INTEGER: 65535
PARALLELS-RMOND-SMI::rmondLicenseVmNumber.0 = INTEGER: 65535
PARALLELS-RMOND-SMI::rmondLicenseCtUsage.0 = INTEGER: 1
PARALLELS-RMOND-SMI::rmondLicenseVmUsage.0 = INTEGER: 0
PARALLELS-RMOND-SMI::rmondLicenseVmUsage.0 = No more variables left in this MIB View (It is past \
the end of the MIB tree)

10.16.3. Description of Virtuozzo Objects

The tables below describe objects you can monitor:

Table 10.16.3.1 Objects related to virtual environments
Object Description
PARALLELS-RMOND-SMI::rmondVeId Virtual environment ID.
PARALLELS-RMOND-SMI::rmondVeName Virtual environment name.
PARALLELS-RMOND-SMI::rmondVeState Virtual environment state.
rPARALLELS-RMOND-SMI::mondVePerfectNode The perfect node for the virtual environment.
PARALLELS-RMOND-SMI::rmondVeMemoryTotal Total memory set for the virtual environment.
PARALLELS-RMOND-SMI::rmondVeMemoryUsage Memory usage inside the virtual environment.
PARALLELS-RMOND-SMI::rmondVeSwapTotal Total swap space set for the virtual environment.
PARALLELS-RMOND-SMI::rmondVeSwapUsage Swap space usage inside the virtual environment.
PARALLELS-RMOND-SMI::rmondVeCpuNumber Number of logical CPU cores set for the virtual environment.
PARALLELS-RMOND-SMI::rmondVeCpuLimit CPU limit set for the virtual environment.
PARALLELS-RMOND-SMI::rmondVeCpuUnits CPU units allocated to the virtual environment.
PARALLELS-RMOND-SMI::rmondVeCpuSystem CPU usage of the system processes inside the virtual environment.
PARALLELS-RMOND-SMI::rmondVeCpuUser CPU usage of the user processes inside the virtual environment.
PARALLELS-RMOND-SMI::rmondVeType Virtual environment type.
PARALLELS-RMOND-SMI::rmondVeUuid Virtual environment UUID reported by the dispatcher.
Table 10.16.3.2 Objects related to VM disks
Object Description
PARALLELS-RMOND-SMI::rmondVeDiskName Full path to the VM hard disk.
PARALLELS-RMOND-SMI::rmondVeDiskTotal Total space of the VM disk.
PARALLELS-RMOND-SMI::rmondVeDiskUsage Used space of the VM disk.
PARALLELS-RMOND-SMI::rmondVeDiskReadRequests Read requests rate of the VM disk.
PARALLELS-RMOND-SMI::rmondVeDiskWriteRequests Write requests rate of the VM disk.
PARALLELS-RMOND-SMI::rmondVeDiskReadBytes Read rate of the VM disk, in bytes.
PARALLELS-RMOND-SMI::rmondVeDiskWriteBytes Write rate of the VM disk, in bytes.
PARALLELS-RMOND-SMI::rmondVeDiskHash1 Low-order 32 bits of the VM disk hash.
PARALLELS-RMOND-SMI::rmondVeDiskHash2 High-order 32 bits of the VM disk hash.
Table 10.16.3.3 Objects related to VE network interfaces
Object Description
PARALLELS-RMOND-SMI::rmondVeNetworkInterface Network interface name of the virtual environment.
PARALLELS-RMOND-SMI::rmondVeNetworkInBytes Incoming traffic, in bytes, received through the VE network interface.
PARALLELS-RMOND-SMI::rmondVeNetworkOutBytes Outgoing traffic, in bytes, sent through the VE network interface.
PARALLELS-RMOND-SMI::rmondVeNetworkInPackets Incoming traffic, in packets, received through the VE network interface.
PARALLELS-RMOND-SMI::rmondVeNetworkOutPackets Outgoing traffic, in packets, sent through the VE network interface.
PARALLELS-RMOND-SMI::rmondVeNetworkMacAddress MAC address of the VE network interface.
Table 10.16.3.4 Objects related to attributes
Object Description
PARALLELS-RMOND-SMI::rmondVeVCpuOrdinal Virtual CPU ordinal numbers inside the virtual environment.
PARALLELS-RMOND-SMI::rmondVeVCpuTime Virtual CPU execution time inside the virtual environment, in nanoseconds.
PARALLELS-RMOND-SMI::rmondLocalVeNumber Number of virtual environments on the host.
PARALLELS-RMOND-SMI::rmondVeLimit Allowed number of virtual environments on the host defined by the user.
PARALLELS-RMOND-SMI::rmondLicenseVeNumber Allowed number of virtual environments on the host defined by the license.
PARALLELS-RMOND-SMI::rmondLicenseCtNumber Allowed number of containers on the host defined by the license.
PARALLELS-RMOND-SMI::rmondLicenseVmNumber Allowed number of virtual machines on the host defined by the license.
PARALLELS-RMOND-SMI::rmondLicenseCtUsage Allowed usage of containers defined by the license.
PARALLELS-RMOND-SMI::rmondLicenseVmUsage Allowed usage of virtual machines defined by the license.