Get command line access with SSH or ESXi Console as user root.

Then run the following commands to enable SNMP and configure SNMP v2 community, SysLocation and SysContact.

esxcli system snmp set -r
esxcli system snmp set -c esxsnmpusr
esxcli system snmp set -p 161
esxcli system snmp set -L "California, USA"
esxcli system snmp set -C [email protected]
esxcli system snmp set -e yes

Finally run ‘get’ to confirm the configuration

esxcli system snmp get

   Authentication:
   Communities: esxsnmpusr
   Enable: true
   Engineid: 00000000000000aaaaaa1000
   Hwsrc: indications
   Largestorage: true
   Loglevel: info
   Notraps:
   Port: 161
   Privacy:
   Remoteusers:
   Syscontact: [email protected]
   Syslocation: California, USA
   Targets:
   Users:
   V3targets:

That’s it, now open your favorite NMS software and start monitoring, at work I use Cisco Prime NAM, my choice at home is Observium


2 responses to “Enable and configure SNMP in vSphere 6 (ESXi)”

  1. Scott Bowden Avatar
    Scott Bowden

    What does the “Largestorage: true” indicate? We are having intermittent SNMP problems with 4 hosts and that is the only difference I see in the config.

    1. Jay Avatar

      largestorage is basically a display option to fit large numbers within 32bit int for snmp. See for source:
      https://pubs.vmware.com/vsphere-6-5/index.jsp?topic=%2Fcom.vmware.vcli.ref.doc%2Fesxcli_system.html

      but it might also point to that large storage as a source of the issue, that’s the only difference between hosts that have the issue vs ones that dont.

      ps: sorry about the late response askimet thought the comment was spam 🙁

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.