This post is more than 5 years old

33 Posts

188668

June 15th, 2012 12:00

Reporting on services not working

I am able to report on clusters and data centers, but if I create a service with service builder and populate it with VMs, none of the reports show any data when run against these services.

Do I need to wait for data to be populated after creating the server? Or do I need to customize the service to make reporting work properly?

Totally confused as always with the inscrutable foglight interface.

Any help much appreciated.

171 Posts

June 18th, 2012 13:00

What is the display name in vCenter?  Are the capitalized?  Rules are case sensitive, so you may have to do SRV vs. srv.  The name that the host picks up is almost always lowercase vs. a VM.

171 Posts

June 15th, 2012 16:00

Essentially, what you need is something like a UI Query that returns all of the VMs in the service so you can then build a view based on those inside of the service.  There is an example of this in my core community cartridge and attached is an image of what the definition of the query looks like to make it work.

getServiceVMs.jpg

132 Posts

June 15th, 2012 17:00

Are you using a custom report to test your service, and does that custom report work with the VMWare service?

As Tom says, the trick is not in the service, it's in the report consuming the service. 

Try running a standard report, using your new service.  If that works, then it's the report spec.

And, no, you can't select the service from the dropdown on the VMWare Environment page,

that page has a bug which prevents it from using custom service definitions, even though they appear in the list.

171 Posts

June 15th, 2012 17:00

You should be able to use any service in the VMware environment page if you mark it as being part of the VMware domain.  The only thing that the VMware environment page should care about is that it filters out any services with the name ESX or ResourcePool in it.

171 Posts

June 15th, 2012 17:00

I've got about 60 different services I've created via service builder that all show up in the drop down list in VMware Environment.  You are on 6.6.1?  It should work with no issues.  If the service somehow has a name that is part of the query filter that could explain it.  That view has a filter on a slew of words.

query.jpg

132 Posts

June 15th, 2012 17:00

Yes, FSMDynamicManagedComponent, service contains around 200 VMs, tests fine, and works great with the standard reports.  Wierd, I know.

132 Posts

June 15th, 2012 17:00

The services show up on the dashboard dropdown list, they just don't display any data.

Perhaps that dashboard is limited in some other way.

132 Posts

June 15th, 2012 17:00

Yep, you would think so, but no.

171 Posts

June 15th, 2012 17:00

That's why, the DMC is technically a layer or two deeper than those queries/functions look.  If they are in the root of the service they should enumerate.

171 Posts

June 15th, 2012 17:00

That's even stranger, it's not enumerating the contents of the service?  Are they in a Dynamic Managed Component?

132 Posts

June 15th, 2012 18:00

Understand, but still a bug in the design for the dashboard.

171 Posts

June 15th, 2012 18:00

So, I can fix this one very easily for you John.  There is a function that rolls through the objects and it just needs a case for the DMC, so a whole 3 lines of code extra!  It seems to be working just fine on my box, but I would test it first.

Edit the Function in VMware -> getTopologyObjectFromNestedServices

At the very bottom of this script is a switch (TOType).

// PART OF THE FILE LOOKS LIKE THIS

case "FSMService":

property = "definition";

break

//ADD THIS CODE BELOW

case "FSMDynamicManagedComponent":

property = "components";

break

//REST OF CODE CONTINUES AS NORMAL!

132 Posts

June 17th, 2012 20:00

Awesome, works perfectly now.  Probably should forward this to the vFoglight devs for inclusion in the next release.

171 Posts

June 17th, 2012 21:00

You bet!  I sent it on Friday after our chat here

33 Posts

June 18th, 2012 10:00

Apologies for the obvious question but what is and how do you make a UI query?

No Events found!

Top