Skip to end of metadata
Go to start of metadata

SNMP is a relatively simple protocol to use; each Vivi box is running an instance of snmpd, an SNMP client that can be queried for information by an SNMP manager. The SNMP manager used for testing the service is snmp, which can be installed on linux systems using apt-get install snmp. SNMP manager functionality is also bundled into larger network managers such as Microsoft SCOM or Tobi Oetiker’s Multi Router Traffic Grapher.

 

The data that can be queried using SNMP is organized into a MIB (management information base) which is a tree-like hierarchical structure where every node is identified by an OID (object identifier). Vivi currently exposes CPU, network and memory information which is all available in the snmp-mibsdownloader package. If you do not download snmp-mibs-downloader you will still be able to access the same information from the Vivi boxes, however it will have values such as 1.3.6.1.4 instead of ISPorg.dod.internet.private. 

The SNMP client responds to UDP requests on port 161 that have authenticated with the correct credentials. If you are using snmp, paste the text on the right into /etc/snmp/snmp.conf Note: if you haven’t downloaded the MIBs,uncomment line 4.


Collecting data

This will differ depending on the program that you are using, but all approaches will end up sending a single message to each box with the information that they would like collected. On a linux machine, you would run snmpwalk to query multiple fields at once, and snmpget to query a single field. For example, run the following command to get all information from the Vivi box at 192.168.3.54:

It will return data that begins with this:

To query only a certain field, you can simply type that field after the IP address:

  • No labels