Purpose:
This article will walk-through the steps required to enable SNMPv3 on Versa Director(10.192.219.100) and Analytics(10.192.12.125) running 18.04.
Configuration Steps:
Enabling SNMPv3 polling on Versa Director and Analytics requires tweaking on the SNMPD configs in the Ubuntu shell. The following steps will help to enable polling and the configuration is same on both Director and Analytics.
1. Modify the /etc/snmp/snmpd.conf file to listen on the address & port 161
####Change the agentAddress section to listen on the Northbound IP address####
agentAddress udp:10.192.219.100:161
#############
2. ADD/Create Users along with password that will be used by the SNMP poller for polling in the /etc/snmp/snmpd.conf file.
####Add the below user with bootstrap at the end of the file####
createUser
bootstrap MD5
Lab1234@ DES
#############
3. Add Access-Controls permissions for the above user under Access-Control section in /etc/snmp/snmpd.conf as below.
####Assign read-write permissions for the bootstrap user####
rwuser
bootstrap priv
#############
4. Restart the snmpd service.
#############
sudo service snmpd restart
#############
Verification:
Perform a SNMPv3 WALK/GET/BULKGET from the SNMP poller machine. Use the below command with the above user and credentials.
Example 1 - Getting CPU Statistics:
lab@root:~$ snmpbulkget -u bootstrap -l authPriv -a MD5 -x DES -A Lab1234@ -X Lab1234@ 10.192.219.100 1.3.6.1.4.1.2021.10.1.3.1
Example 2 - Fetching Interface Names:
lab@root:~$ snmpbulkget -u bootstrap -l authPriv -a MD5 -x DES -A Lab1234@ -X Lab1234@ 10.192.219.100 1.3.6.1.2.1.2.2.1.2
####################
iso.3.6.1.2.1.2.2.1.2.1 = STRING: "lo"
iso.3.6.1.2.1.2.2.1.2.2 = STRING: "eth0"
iso.3.6.1.2.1.2.2.1.2.3 = STRING: "eth1"
iso.3.6.1.2.1.2.2.1.2.4 = STRING: "docker0"
iso.3.6.1.2.1.2.2.1.3.1 = INTEGER: 24
iso.3.6.1.2.1.2.2.1.3.2 = INTEGER: 6
iso.3.6.1.2.1.2.2.1.3.3 = INTEGER: 6
iso.3.6.1.2.1.2.2.1.3.4 = INTEGER: 6
iso.3.6.1.2.1.2.2.1.4.1 = INTEGER: 65536
iso.3.6.1.2.1.2.2.1.4.2 = INTEGER: 1200
#####################
Example 2 - Fetching Interface Statistics:
lab@root:~$ snmpbulkget -u bootstrap -l authPriv -a MD5 -x DES -A Lab1234@ -X Lab1234@ 10.192.219.100 1.3.6.1.2.1.2.2.1.10
####################
iso.3.6.1.2.1.2.2.1.10.1 = Counter32: 413237926
iso.3.6.1.2.1.2.2.1.10.2 = Counter32: 3578965540
iso.3.6.1.2.1.2.2.1.10.3 = Counter32: 287885358
iso.3.6.1.2.1.2.2.1.10.4 = Counter32: 0
iso.3.6.1.2.1.2.2.1.11.1 = Counter32: 63030331
iso.3.6.1.2.1.2.2.1.11.2 = Counter32: 35153038
iso.3.6.1.2.1.2.2.1.11.3 = Counter32: 820300
iso.3.6.1.2.1.2.2.1.11.4 = Counter32: 0
iso.3.6.1.2.1.2.2.1.12.1 = Counter32: 0
iso.3.6.1.2.1.2.2.1.12.2 = Counter32: 0
#####################
Example 3 - Fetching Analytics Ubuntu Version:
lab@root:~$ snmpget -u bootstrap -l authPriv -a MD5 -x DES -A Lab1234@ -X Lab1234@ 10.192.12.125 1.3.6.1.2.1.1.1.0
####################
iso.3.6.1.2.1.1.1.0 = STRING: "Linux versa-analytics 4.15.0-99-generic #100-Ubuntu SMP Wed Apr 22 20:32:56 UTC 2020 x86_64"
###################
Example 4 - Fetching CPU Load:
lab@root:~$ snmpwalk -u bootstrap -l authPriv -a MD5 -x DES -A Lab1234@ -X Lab1234@ 10.192.12.125 1.3.6.1.4.1.2021.10.1
###################
iso.3.6.1.4.1.2021.10.1.1.1 = INTEGER: 1
iso.3.6.1.4.1.2021.10.1.1.2 = INTEGER: 2
iso.3.6.1.4.1.2021.10.1.1.3 = INTEGER: 3
iso.3.6.1.4.1.2021.10.1.2.1 = STRING: "Load-1"
iso.3.6.1.4.1.2021.10.1.2.2 = STRING: "Load-5"
iso.3.6.1.4.1.2021.10.1.2.3 = STRING: "Load-15"
iso.3.6.1.4.1.2021.10.1.3.1 = STRING: "0.01"
iso.3.6.1.4.1.2021.10.1.3.2 = STRING: "0.03"
iso.3.6.1.4.1.2021.10.1.3.3 = STRING: "0.00"
iso.3.6.1.4.1.2021.10.1.4.1 = STRING: "12.00"
iso.3.6.1.4.1.2021.10.1.4.2 = STRING: "10.00"
iso.3.6.1.4.1.2021.10.1.4.3 = STRING: "5.00"
iso.3.6.1.4.1.2021.10.1.5.1 = INTEGER: 1
iso.3.6.1.4.1.2021.10.1.5.2 = INTEGER: 3
iso.3.6.1.4.1.2021.10.1.5.3 = INTEGER: 0
iso.3.6.1.4.1.2021.10.1.6.1 = Opaque: Float: 0.010000
iso.3.6.1.4.1.2021.10.1.6.2 = Opaque: Float: 0.030000
iso.3.6.1.4.1.2021.10.1.6.3 = Opaque: Float: 0.000000
iso.3.6.1.4.1.2021.10.1.100.1 = INTEGER: 0
iso.3.6.1.4.1.2021.10.1.100.2 = INTEGER: 0
iso.3.6.1.4.1.2021.10.1.100.3 = INTEGER: 0
iso.3.6.1.4.1.2021.10.1.101.1 = ""
iso.3.6.1.4.1.2021.10.1.101.2 = ""
iso.3.6.1.4.1.2021.10.1.101.3 = ""
####################
Example 5 - RAM Free:
snmpget -u bootstrap -l authPriv -a MD5 -x DES -A Lab1234@ -X Lab1234@ 10.192.219.100 1.3.6.1.4.1.2021.4.11.0
####################
iso.3.6.1.4.1.2021.4.11.0 = INTEGER: 4893736
#####################
NOTE: All the above UIDs are Ubuntu specific. There are no Versa specific MIBs available for SNMP polling for Director and Analytics.
Some popular Ubuntu OIDs:
Network Interface Statistics
################
List NIC names: .1.3.6.1.2.1.2.2.1.2
Get Bytes IN: .1.3.6.1.2.1.2.2.1.10
Get Bytes IN for NIC 4: .1.3.6.1.2.1.2.2.1.10.4
Get Bytes OUT: .1.3.6.1.2.1.2.2.1.16
Get Bytes OUT for NIC 4: .1.3.6.1.2.1.2.2.1.16.4
################
CPU Statistics
################
Load
1 minute Load: .1.3.6.1.4.1.2021.10.1.3.1
5 minute Load: .1.3.6.1.4.1.2021.10.1.3.2
15 minute Load: .1.3.6.1.4.1.2021.10.1.3.3
################
CPU times
################
percentage of user CPU time: .1.3.6.1.4.1.2021.11.9.0
raw user cpu time: .1.3.6.1.4.1.2021.11.50.0
percentages of system CPU time: .1.3.6.1.4.1.2021.11.10.0
raw system cpu time: .1.3.6.1.4.1.2021.11.52.0
percentages of idle CPU time: .1.3.6.1.4.1.2021.11.11.0
raw idle cpu time: .1.3.6.1.4.1.2021.11.53.0
raw nice cpu time: .1.3.6.1.4.1.2021.11.51.0
################
Memory Statistics
################
Total Swap Size: .1.3.6.1.4.1.2021.4.3.0
Available Swap Space: .1.3.6.1.4.1.2021.4.4.0
Total RAM in machine: .1.3.6.1.4.1.2021.4.5.0
Total RAM used: .1.3.6.1.4.1.2021.4.6.0
Total RAM Free: .1.3.6.1.4.1.2021.4.11.0
Total RAM Shared: .1.3.6.1.4.1.2021.4.13.0
Total RAM Buffered: .1.3.6.1.4.1.2021.4.14.0
Total Cached Memory: .1.3.6.1.4.1.2021.4.15.0
################
Disk OID's
################
Path where the disk is mounted: .1.3.6.1.4.1.2021.9.1.2.1
Path of the device for the partition: .1.3.6.1.4.1.2021.9.1.3.1
Total size of the disk/partion (kBytes): .1.3.6.1.4.1.2021.9.1.6.1
Available space on the disk: .1.3.6.1.4.1.2021.9.1.7.1
Used space on the disk: .1.3.6.1.4.1.2021.9.1.8.1
Percentage of space used on disk: .1.3.6.1.4.1.2021.9.1.9.1
Percentage of inodes used on disk: .1.3.6.1.4.1.2021.9.1.10.1
################
System Uptime: .1.3.6.1.2.1.1.3.0