Monitor vCenter Appliance (vCSA) via SNMP

Monitor vCenter Appliance (vCSA) via SNMP

Monitor vCenter Appliance (vCSA) via SNMP 200 125 Roderick Derks

As we all rely more and more on vCenter for managing datacenters with VMware ESX hosts and for delivering our virtual desktops, we have to be sure vCenter services are running smootly. So monitoring is important.

First there was only vCenter on a Windows host. Works fine. Monitoring was possible because you controlled the Windows box and the database. Now there is the new vCenter Virtual Appliance running on SuSE 11.1. Very interesting and probably the way to go in the future. But how to monitor the vCenter services?

For monitoring I mostly use Simple Network Monitoring Protocol (SNMP). Really great, not simple. The vCenter appliance has not got the SNMP daemon installed by default, so some activity is required. Glad we have root access to the machine. Here we go:

Check the Suse version:

# cat /etc/SuSE-release SUSE Linux Enterprise Server 11 (x86_64) VERSION = 11 PATCHLEVEL = 1 

Add the repository of this Suse version to YAST, the Suse software manager tool. Use SSH to login to the vCenter server.

# yast 
  • Select Software > Software Repositiries
  • Select Add
  • Select Specify URL and select next
  • Add a Repository name and the URL http://download.opensuse.org/distribution/11.1/repo/oss/
  • Add the SNMP software: go back to the initial YAST screen and select Software > Software Management
  • In the SEARCH PHRASE field type SNMP and press enter
  • Select net-snmp, dependencies are selected automatically (in vCSA 5.1 I broke the dependencies and this worked)
  • Select ACCEPT

The software is installed. Quit YAST.

Allow the monitoring server to connect to the snmpd daemon:

# vi /etc/hosts.allow sshd: ALL : ALLOW snmpd: ALL : ALLOW ALL: KNOWN 

Start the SNMP daemon and make sure it starts after a reboot:

# service snmpd start # chkconfig snmpd on # vi /etc/snmp/snmpd.conf

Change

rwcommunity public 127.0.0.1

to

rwcommunity public

Now try a snmp quey from the monitoring server:

# snmpwalk -v2c -c public vcenter01.r71.nl SNMPv2-MIB::sysDescr.0 = STRING: Linux vcenter01.r71.nl 2.6.32.29-0.3-default SNMPv2-MIB::sysObjectID.0 = OID: NET-SNMP-TC::linux DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (169539) 0:28:15.39 SNMPv2-MIB::sysContact.0 = STRING: Roderick SNMPv2-MIB::sysName.0 = STRING: vcenter01.r71.nl SNMPv2-MIB::sysLocation.0 = STRING: R71 .. 

It works!

Now configure your monitoring tool. If you don't have a good monitoring tool (shame on you) then get 360° Viewpoint!
(next I'm trying to figure out how to monitor the DB2 database, will report back later when ready)

 

Roderick Derks

Liefhebber van fietsen, van het oplossen van IT puzzels, en van het delen van informatie om anderen te helpen.

All stories by:Roderick Derks

Leave a Reply

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

    Your Name (required)

    Your Email (required)

    Subject

    Your Message

      Your Name (required)

      Your Email (required)

      Subject

      Your Message