HowTo activate SNMP on vSphere 6.0 hosts

Monitoring ESXi with an standard open source monitoring tool usually requires SNMP. Searching for SNMP in the vCenter configuration context this simply allows you to start the service – but not exactly leads to success in the first place. Probably you get an error.

You check in the security profiles and find the service stopped although it is configured to start with the host. Manual start delivers an “ooops”.

Looking for an clickable configuration context did not lead to an solution I was aware of. So finally you have to activate SNMP through the esxcli:

First set SNMP to read only.

esxcli system snmp set -r

Then set the community

esxcli system snmp set -c mycommunity

Now set SNMP to the appropriate port. I am not aware of ESX using automatically the right default value of 161 so we need to set it again.

esxcli system snmp set -p 161

Then good style is to set location and contact.

esxcli system snmp set -L "My Location"
esxcli system snmp set -C

And last enable the service.

esxcli system snmp set -e yes

Finally you should be able to access the SNMP service with the appropriate credentials. An snmpwalk shows that you get proper standard process and memory information, some information about mounted partitions. Network interface statistics are awesome, and ESXi distinguishes between physical and virtual interfaces and allows to monitor even the virtual switches, even if you don’t use a CISCO v1000.


Leave a Reply

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