How to Avoid “” in SNMP Trap With vCenter Server Virtual Appliance

SNMP trap provides a very useful way to monitor vSphere. You can use either GUI or vSphere API to configure up to 4 trap receivers. With that I can use alarm to monitor events or state changes.

If you use vSphere API to add SNMP receivers, you will need the OptionManager managed object. The related options you want to set are:, snmp.receiver.1.port,, snmp.receiver.1.enabled. There are 3 more sets with similar names but different numbers (2, 3, 4).

Bothered by SLOW Web UI to manage vSphere? Want to manage ALL your VMware vCenters, AWS, Azure, Openstack, container behind a SINGLE pane of glass? Want to search, analyze, report, visualize VMs, hosts, networks, datastores, events as easily as Google the Web? Find out more about vSearch 3.0: the search engine for all your private and public clouds.

If you prefer the GUI, just go to the Home and click on “vCenter Server Settings.” In the dialog box, pick the SNMP from left side list and then enter the IP address of your receiver in the URL under the primary receiver, which is also the first there. Keep the rest as they are and then click OK to save it.

Everything works perfect until I checked my trap receiver after setting up an alarm to monitor virtual machine power off events. Not really true as I did get into another issue with firewall on my Windows 7. But that’s not vSphere issue. Turning off the firewall worked. It may not be a good idea but not a bad hack if you want a quick result.

For my test purpose, I used a free GUI tool called Trap Receiver ( From the GUI, I could see the IP address of sender column is “”. Because I ran vCenter and Trap Receiver on two different machines, I know it’s not right. The vCenter appliance had its own static IP address.

This issue turned out to be only with the virtual appliance which is based Linux. On Windows OS, there was no such issue.

To fix the problem, I tried to change the vCenter name and managed IP address within the vCenter Server Settings” dialog box. It’s interesting that the vCenter server name is categorized in “Runtime Settings.” I think it should be either “General” or simply “Name Settings” because the vCenter name does not seem to me as something runtime per se.

After that, the IP in the SNMP remained to be Inspired by a friend, I started to look at the /etc/hosts file. Even after I change the vCenter name from localhost to “vCSA,” the files remains to look like this: vCSA localhost

To try it out, I add one more entry on top vCSA

After that things started to work and I could see the send IP address become The problem solved.

It’s not clear to me whether the issue is there if the vCenter server appliance has joined a domain by Active Directory. For lab, you probably don’t need to. In case you ran into this issue, just try this walk around.

This entry was posted in Virtualization and tagged , , . Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

One Comment

  1. Posted April 24, 2013 at 12:31 am | Permalink

    How to Avoid “” in SNMP Trap With vCenter Server Virtual Appliance (DoubleCloud)

Post a Comment

Your email is never published nor shared. Required fields are marked *


You may use these HTML tags and attributes <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>


    My company has created products like vSearch ("Super vCenter"), vijavaNG APIs, EAM APIs, ICE tool. We also help clients with virtualization and cloud computing on customized development, training. Should you, or someone you know, need these products and services, please feel free to contact me: steve __AT__

    Me: Steve Jin, VMware vExpert who authored the VMware VI and vSphere SDK by Prentice Hall, and created the de factor open source vSphere Java API while working at VMware engineering. Companies like Cisco, EMC, NetApp, HP, Dell, VMware, are among the users of the API and other tools I developed for their products, internal IT orchestration, and test automation.