Linux

Installing SNMP in Ubuntu 18.04

Here are the simple steps to install SNMP in Ubuntu 18.04
Reference: https://support.auvik.com/hc/en-us/articles/204221884-How-to-enable-SNMP-on-Linux-based-servers-workstations

apt-get update && apt-get install snmp snmpd snmp-mibs-downloader

Next, using your text editor, edit /etc/snmp/snmpd.conf to look like this:
# this will make snmpd listen on all interfaces

agentAddress  udp:161

# Or make it listen only to the local private network interface eg. eth0(192.168.100.3)

agentAddress  udp:192.168.100.3:161

# a read only community ‘local’ and the source network* is defined

rocommunity local 172.17.1.0/16

Note: Make sure your firewall opens the port 161.
Restart the SNMP Daemon

service snmpd restart

Testing the SNMP service locally

snmpwalk -v 2c -c public localhost