You can use the ESXi embedded SNMP agent to send virtual machine and environmental traps to management systems. To configure the agent to send traps, you must specify a target address and community.

To send traps with the SNMP agent, you must configure the target (receiver) address, community, and an optional port. If you do not specify a port, the SNMP agent sends traps to UDP port 162 on the target management system by default.

SNMP configuration for ESXi requires the vSphere Command-Line Interface. See Getting Started with vSphere Command-Line Interfaces.


From the vSphere CLI, type --server hostname --username username --password password -t target_address@port/community.

Replace target_address, port, and community with the address of the target system, the port number to send the traps to, and the community name, respectively. Each time you specify a target with this command, the settings you specify overwrite all previously specified settings. To specify multiple targets, separate them with a comma.

For example, to send SNMP traps from the host to port 162 on using the public community, type --server --username user --password password -t


(Optional) If the SNMP agent is not enabled, enable it by typing --server hostname --username username --password password --enable.


(Optional) Send a test trap to verify that the agent is configured correctly by typing --server hostname --username username --password password --test.

The agent sends a warmStart trap to the configured target.