This information was stolen from vmtn.net
http://www.vmware.com/community/message.jspa?messageID=423354
Re: SNMP Information from ESX3
Posted: Sep 29, 2006 8:48 AM in response to: cklemmer
Click to reply to this topic Reply
first edit snmpd.conf
- vi /etc/snmp/snmpd.conf
configure it to point to the management server IP address
use a community name (here it’s public)
trapsink *.*.*.*
trapcommunity public
then start snmpd service
- service snmpd start
configure it to autostart
- chkconfig snmpd on
test it on local machine
- snmpwalk -v 1 -c public localhost system
test it on another system (x.x.x.x is the esx server’s IP)
- snmpwalk -v 1 -c public x.x.x.x system
configure your management server to receive SNMP and act upon.
This article applies to VMware ESX 3.0.1 in addition to older versions 2.5.3 - 3.0
VMware ESX server has snmpd daemon that can be used to monitor performance and send snmp traps
Virtual Center monitor many performance metrics, like CPU, Memory, network and disk I/O, but it is expensive and it is limited to those metrics.
What if you need to monitor disk space on /var/log partition? and want to receive an alert when it reaches 90%; What if you want to monitor httpd on ESX and receive a message when it fails.
If you are working in an environment with many servers and a team of systems administrators, you are most likely using a system monitoring tool or at least evaluating one.
* Edit snmpd.confWhatsup pro
# vi /etc/snmp/snmpd.conf
* Configure it to point to the management server IP address and use a community name (here it’s public)
trapsink *.*.*.* trapcommunity public
* Then start snmpd service
# service snmpd start
* Configure it to autostart
# chkconfig snmpd on
* Test it on local machine
#snmpwalk -v 1 -c public localhost system
* Test it on another system (x.x.x.x is the esx server’s IP)
#snmpwalk -v 1 -c public x.x.x.x system
* Open the firewall esxcfg-firewall -o 162,tcp,in,snmp
* Go to Whatsup machine (or any management station your have like Dell Open Manage IT Assistant or Nagios)
* Compile ESX MIBs from ESX server
/usr/lib/vmware/snmp/mibs/
VMWARE-ESX-MIB.mib
VMWARE-RESOURCES-MIB.mib
VMWARE-ROOT-MIB.mib
VMWARE-SYSTEM-MIB.mib
VMWARE-TRAPS-MIB.mib
VMWARE-VMINFO-MIB.mib
* If you haven’t added the server to be monitored yet, run discovery or add device to add the server to the database
* Create monitors for SNMP and configure credentials and communities (public, private etc…)
* Open the firewall on the management station ( here it is Whatsup pro)
* Write click the machine you want to monitor and select the monitored items (ping, http, cpu, disk space… etc.)
* Configure the actions to be triggered (email, page, event log…)