Monday, June 17, 2013

Monitor a Windows Service with Hyperic and vC Ops

A question appeared this morning on the vC Ops VMware Community forum that I thought would be a helpful blog post.

"Is it possible to monitor the services on the VM's?"

The answer is "yes" and this is done through the wonderful integration of Hyperic and vC Ops.  Another response to this question is "yes, with vCM" and while that is true, it is a slightly different use case.  I will explain quickly.

  - With Hyperic monitoring the service, you can not only get real time availability of the service (i.e. is it up or down?) but also get monitoring on performance and apply the vC Ops analytics to those service metrics.

  - With vCM you can validate if a service is in a particular state (running, not running, manual, automatic, disabled, etc) to enforce your server best practices, security and compliance.  This is not a real time status of the service but rather a configuration check of the service at an interval you specify.

I will assume the question is for the Hyperic use case and explain how to configure monitoring for a Windows service - I'll post the same for Linux, provided I get requests, but once you understand the Windows settings you should be able to figure the Linux side out for yourself.

I also assume that you have Hyperic running, you have integrated it with vC Ops and that you have one or more Windows systems monitored by Hyperic.  See my blog post "vC Ops and Hyperic - Dynamic Duo of Enterprise Management" if you need help getting started.

First, from the platform browser of you Windows server, select Tools > New Platform Service as below.  I am using my vCAC server running Windows 2008R2 in this example.

In the New Service setup, define a name, description (optional) and select the Windows Service from the Service Type pull down menu.  Note the other service types - I highly recommend you explore those as well.  Click OK to continue.

After clicking OK in the service setup above you will be presented with the properties page for the new service.  Click the "Configuration Properties" hyperlink.

You will need the service name here.  To get that, open the properties for the service on your Windows system and record the service name.

Then use that service name in the configuration properties and click OK.

In about 5 minutes, you will have the metric data displayed for the default metrics as indicated in the screen cap below.  If you expose all metrics by clicking "Show All Metrics" you can enable collection for the other metrics available.  

 A full list is provided in the vFabric Hyperic Resource Configuration and Metrics Guide but I have included the table below for your reference.

Now, if you have vC Ops configured with the Hyperic adapter, then those metrics will now appear in the Custom UI and can be added to your dashboards.

Wednesday, June 12, 2013

Hyperic 5.7 Released - vApp Upgrade Overview

Hyperic 5.7 went GA this week and while upgrading the vApp is pretty easy, there's some info not included in the documentation that can help you get through this quickly.

First, the vApp upgrade steps in the "Getting Started with vFabric Hyperic 5.7 Guide" don't tell you which file (of the dozen or so available on the VMware download site) to use.  You want to grab the file hyperic-hqee-installer-x86-64-linux-5.7.0.tar.gz for this upgrade.

You will need to place the file on an FTP or Web server you can access from the Hyperic vApp.  You will be using the VAMI interface at https://:5480 to perform this upgrade.  In my case, I just put it on my lab FTP server and enabled anonymous login so the wget process run by the VAMI upgrade can download the file.

Here's a screen shot of the install - be sure to get a snapshot of your Hyperic VMs before starting the upgrade!  These screens show you all you need to know....

Starting the upgrade....

...upgrade finished!!

You may want to upgrade your agents - there are some fixes for a couple of the plugins, most notably Windows AD 2008 monitoring is finally working!  Thankfully, this is a pretty pain free process as well.  What I recommend is to create a group for all of the HQ Agent "servers" so you can upgrade at one time.

To do this, you select "New Group" from the Tools menu under the Browse tab - as below.

NOTICE - my "Group Type" is "HQ Agent"....

Now I can select that group, and click the "ADD TO LIST" under the Resources table....

Just select all of your servers...

...and move them over to the right hand "Add Resources" table and click "OK"

Now you are ready to upgrade the whole group, by selecting "Views" and then "Agent Commands" for the group.  The agent operation you want is, of course, "upgrade"

And that's it - after a while (my lab only took a few minutes for the half-dozen servers) you can verify the agent version by browsing to the server and selecting it.

Monday, June 10, 2013

vC Ops - How to Edit Your Balanced Metrics Profile

NOTE - adding metrics to the balanced profile can impact the sizing and performance of your vC Ops vApp.  Be very conservative with the metrics you add and only add them as required.  As always, I highly recommend you consult VMware support directly before making any changes to your vC Ops vApp.

Beginning with version 5.7, you can choose to have the vApp collect a subset of the vCenter metrics with vC Ops.  This is about a 50% reduction in the amount of metrics collected and has a few benefits.

 - the vApp will support approximately 12,000 VMs with this profile
 - Analytics calculation will use less CPU and memory
 - overall reduction in resources required for the vApp

You must enable this, as it is not turned on by default, through the Admin UI.  Screen shot below shows how.  **UPDATE** as of version 5.8 the "Balanced Profile" is the default setting.

For those using this, I did uncover a tiny little issue while talking to a customer today.  At least one of the heat maps in the vSphere UI relies on a metric that is not collected with the balanced profile applied.  The result is a heat map that looks something like this:

So, in this case, the metric we need to add is "Network:Aggregate of all Instances | Dropped Packets" to get the heat map coloration working.

It is possible to add metrics to the balanced profile, but it requires access to the Custom UI.  So, you need to be running Advanced or Enterprise for this capability.

Log into the Custom UI, go to Environment > Configuration > Attribute Packages.

  From there, pull down the VMware adapter kind and then the resource kind for which you need to add the metric.  In our case, this is Host System. You will see two Attribute Packages - Default Attributes and All Attributes.

  Default Attributes = Balanced Profile
  All Attributes = Full Profile

Just a note, that when you select Balanced Profile in the Admin UI, vC Ops is changing the default attribute package to Default Attributes for all VMware resources - otherwise, you'd have to do this manually and that would suck! :)

Now, edit the Default Attributes (just select it and click the pencil icon).   Again, we need to add a specific metric to get our heat map in working order, so browsing to the network group I will select Dropped Packets.  As you can see in the screen cap below it is not on by default with the balanced profile (aka Default Attributes).

Click the OK button to save.  That's it!

Monday, June 3, 2013

The Truth

I try to stay away from marketing type stuff on my blog - I'm basically here to help and share what I've learned.  But these videos are a lot of fun - enjoy!

PS - my favorite part is when the MS guy freaks out at the mention of "Tuesday" - classic!