Monitoring System Objects via SNMP

You can monitor Virtuozzo Server 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 VIRTUOZZO-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.

Enabling SNMP Access

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

  1. Install the rmond package.

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

    1
    2
    
    rwcommunity pdrs 127.0.0.1 .1.3.6.1.4.1.26171
    rwcommunity pdrs <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.

Accessing System Objects via SNMP

You can access Virtuozzo Server 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:

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

    1
    
    # snmpwalk -m /usr/share/snmp/mibs/VIRTUOZZO-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:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
VIRTUOZZO-RMOND-SMI::rmondVeId."{b5f09b02-7358-4998-860c-c622653859f3}" = STRING: \
{b5f09b02-7358-4998-860c-c622653859f3}
VIRTUOZZO-RMOND-SMI::rmondVeName."{b5f09b02-7358-4998-860c-c622653859f3}" = STRING: centos
VIRTUOZZO-RMOND-SMI::rmondVeState."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: \
running(805306372)
VIRTUOZZO-RMOND-SMI::rmondVePerfectNode."{b5f09b02-7358-4998-860c-c622653859f3}" = STRING:
VIRTUOZZO-RMOND-SMI::rmondVeMemoryTotal."{b5f09b02-7358-4998-860c-c622653859f3}" = Counter64: \
2147483648
VIRTUOZZO-RMOND-SMI::rmondVeMemoryUsage."{b5f09b02-7358-4998-860c-c622653859f3}" = Counter64: \
1788
VIRTUOZZO-RMOND-SMI::rmondVeSwapTotal."{b5f09b02-7358-4998-860c-c622653859f3}" = Counter64: 0
VIRTUOZZO-RMOND-SMI::rmondVeSwapUsage."{b5f09b02-7358-4998-860c-c622653859f3}" = Counter64: 0
VIRTUOZZO-RMOND-SMI::rmondVeCpuNumber."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: 2
VIRTUOZZO-RMOND-SMI::rmondVeCpuLimit."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: 0
VIRTUOZZO-RMOND-SMI::rmondVeCpuUnits."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: 0
VIRTUOZZO-RMOND-SMI::rmondVeCpuSystem."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: 0
VIRTUOZZO-RMOND-SMI::rmondVeCpuUser."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: 0
VIRTUOZZO-RMOND-SMI::rmondVeType."{b5f09b02-7358-4998-860c-c622653859f3}" = INTEGER: vm(0)
VIRTUOZZO-RMOND-SMI::rmondVeUuid."{b5f09b02-7358-4998-860c-c622653859f3}" = STRING: \
{b5f09b02-7358-4998-860c-c622653859f3}
VIRTUOZZO-RMOND-SMI::rmondVeDiskName."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = STRING: /vz/vmprivate/b5f09b02-7358-4998-860c-c622653859f3/harddisk.hdd
VIRTUOZZO-RMOND-SMI::rmondVeDiskTotal."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter64: 0
VIRTUOZZO-RMOND-SMI::rmondVeDiskUsage."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter64: 0
VIRTUOZZO-RMOND-SMI::rmondVeDiskReadRequests."{b5f09b02-7358-4998-860c-c622653859f3}".\
2881840264.645796544 = Counter64: 2
VIRTUOZZO-RMOND-SMI::rmondVeDiskWriteRequests."{b5f09b02-7358-4998-860c-c622653859f3}".\
2881840264.645796544 = Counter64: 16714
VIRTUOZZO-RMOND-SMI::rmondVeDiskReadBytes."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter64: 77824
VIRTUOZZO-RMOND-SMI::rmondVeDiskWriteBytes."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter64: 1073883648
VIRTUOZZO-RMOND-SMI::rmondVeDiskHash1."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter32: 2881840264
VIRTUOZZO-RMOND-SMI::rmondVeDiskHash2."{b5f09b02-7358-4998-860c-c622653859f3}".2881840264.\
645796544 = Counter32: 645796544
VIRTUOZZO-RMOND-SMI::rmondVeNetworkInterface."{b5f09b02-7358-4998-860c-c622653859f3}"."" = STRING:
VIRTUOZZO-RMOND-SMI::rmondVeNetworkInBytes."{b5f09b02-7358-4998-860c-c622653859f3}"."" = \
Counter64: 6743089
VIRTUOZZO-RMOND-SMI::rmondVeNetworkOutBytes."{b5f09b02-7358-4998-860c-c622653859f3}"."" = \
Counter64: 12472
VIRTUOZZO-RMOND-SMI::rmondVeNetworkInPackets."{b5f09b02-7358-4998-860c-c622653859f3}"."" = \
Counter64: 33658
VIRTUOZZO-RMOND-SMI::rmondVeNetworkOutPackets."{b5f09b02-7358-4998-860c-c622653859f3}"."" = \
Counter64: 159
VIRTUOZZO-RMOND-SMI::rmondVeNetworkMacAddress."{b5f09b02-7358-4998-860c-c622653859f3}"."" = \
STRING: 001C42C329B0
VIRTUOZZO-RMOND-SMI::rmondVeVCpuOrdinal."{b5f09b02-7358-4998-860c-c622653859f3}".0 = INTEGER: 0
VIRTUOZZO-RMOND-SMI::rmondVeVCpuOrdinal."{b5f09b02-7358-4998-860c-c622653859f3}".1 = INTEGER: 1
VIRTUOZZO-RMOND-SMI::rmondVeVCpuTime."{b5f09b02-7358-4998-860c-c622653859f3}".0 = Counter64: \
59720000000
VIRTUOZZO-RMOND-SMI::rmondVeVCpuTime."{b5f09b02-7358-4998-860c-c622653859f3}".1 = Counter64: \
26720000000
VIRTUOZZO-RMOND-SMI::rmondLocalVeNumber.0 = INTEGER: 1
VIRTUOZZO-RMOND-SMI::rmondVeLimit.0 = INTEGER: 65535
VIRTUOZZO-RMOND-SMI::rmondLicenseVeNumber.0 = INTEGER: 65535
VIRTUOZZO-RMOND-SMI::rmondLicenseCtNumber.0 = INTEGER: 65535
VIRTUOZZO-RMOND-SMI::rmondLicenseVmNumber.0 = INTEGER: 65535
VIRTUOZZO-RMOND-SMI::rmondLicenseCtUsage.0 = INTEGER: 1
VIRTUOZZO-RMOND-SMI::rmondLicenseVmUsage.0 = INTEGER: 0
VIRTUOZZO-RMOND-SMI::rmondLicenseVmUsage.0 = No more variables left in this MIB View (It is past \
the end of the MIB tree)

Description of System Objects

The tables below describe objects you can monitor:

Table 1. Objects related to virtual environments

ObjectDescription
VIRTUOZZO-RMOND-SMI::rmondVeIdVirtual environment ID.
VIRTUOZZO-RMOND-SMI::rmondVeNameVirtual environment name.
VIRTUOZZO-RMOND-SMI::rmondVeStateVirtual environment state.
rVIRTUOZZO-RMOND-SMI::mondVePerfectNodeThe perfect node for the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeMemoryTotalTotal memory set for the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeMemoryUsageMemory usage inside the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeSwapTotalTotal swap space set for the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeSwapUsageSwap space usage inside the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeCpuNumberNumber of logical CPU cores set for the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeCpuLimitCPU limit set for the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeCpuUnitsCPU units allocated to the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeCpuSystemCPU usage of the system processes inside the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeCpuUserCPU usage of the user processes inside the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeTypeVirtual environment type.
VIRTUOZZO-RMOND-SMI::rmondVeUuidVirtual environment UUID reported by the dispatcher.

Table 2. Objects related to VM disks

ObjectDescription
VIRTUOZZO-RMOND-SMI::rmondVeDiskNameFull path to the VM hard disk.
VIRTUOZZO-RMOND-SMI::rmondVeDiskTotalTotal space of the VM disk.
VIRTUOZZO-RMOND-SMI::rmondVeDiskUsageUsed space of the VM disk.
VIRTUOZZO-RMOND-SMI::rmondVeDiskReadRequestsRead requests rate of the VM disk.
VIRTUOZZO-RMOND-SMI::rmondVeDiskWriteRequestsWrite requests rate of the VM disk.
VIRTUOZZO-RMOND-SMI::rmondVeDiskReadBytesRead rate of the VM disk, in bytes.
VIRTUOZZO-RMOND-SMI::rmondVeDiskWriteBytesWrite rate of the VM disk, in bytes.
VIRTUOZZO-RMOND-SMI::rmondVeDiskHash1Low-order 32 bits of the VM disk hash.
VIRTUOZZO-RMOND-SMI::rmondVeDiskHash2High-order 32 bits of the VM disk hash.

Table 3. Objects related to VE network interfaces

ObjectDescription
VIRTUOZZO-RMOND-SMI::rmondVeNetworkInterfaceNetwork interface name of the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeNetworkInBytesIncoming traffic, in bytes, received through the VE network interface.
VIRTUOZZO-RMOND-SMI::rmondVeNetworkOutBytesOutgoing traffic, in bytes, sent through the VE network interface.
VIRTUOZZO-RMOND-SMI::rmondVeNetworkInPacketsIncoming traffic, in packets, received through the VE network interface.
VIRTUOZZO-RMOND-SMI::rmondVeNetworkOutPacketsOutgoing traffic, in packets, sent through the VE network interface.
VIRTUOZZO-RMOND-SMI::rmondVeNetworkMacAddressMAC address of the VE network interface.

Table 4. Objects related to attributes

ObjectDescription
VIRTUOZZO-RMOND-SMI::rmondVeVCpuOrdinalVirtual CPU ordinal numbers inside the virtual environment.
VIRTUOZZO-RMOND-SMI::rmondVeVCpuTimeVirtual CPU execution time inside the virtual environment, in nanoseconds.
VIRTUOZZO-RMOND-SMI::rmondLocalVeNumberNumber of virtual environments on the host.
VIRTUOZZO-RMOND-SMI::rmondVeLimitAllowed number of virtual environments on the host defined by the user.
VIRTUOZZO-RMOND-SMI::rmondLicenseVeNumberAllowed number of virtual environments on the host defined by the license.
VIRTUOZZO-RMOND-SMI::rmondLicenseCtNumberAllowed number of containers on the host defined by the license.
VIRTUOZZO-RMOND-SMI::rmondLicenseVmNumberAllowed number of virtual machines on the host defined by the license.
VIRTUOZZO-RMOND-SMI::rmondLicenseCtUsageAllowed usage of containers defined by the license.
VIRTUOZZO-RMOND-SMI::rmondLicenseVmUsageAllowed usage of virtual machines defined by the license.