How do I retrieve statistics from the VMM database
-
Thursday, March 01, 2012 11:18 AM
I want to be able to query the virtual machine manager database so that I can build reports/dashboards based on statistics stored there.
I have access to the database and can query all the tables but I cant seem to link together or find some of the information I am looking for. For example i want to be able to show each VM with how much hard drive space it is using and how much it is allocated etc.. I can retrieve things such as ram and processor data and can see tables for VHD's and drives but I'm not sure how they piece together.
If anyone has any experience with doing this or knows a bit more about the actual schema that would be great.
Thanks in advance
All Replies
-
Wednesday, March 14, 2012 11:55 PM
Is this VMM 2012 or VMM 2008R2? In 2012, we have provided powershell cmdlet and UI for getting the performance data of hosts and VMs.
Additionally, you can hook-up VMM server with OM server and get the built-in reports provided by VMM.
- Marked As Answer by Kristian NeseMVP, Moderator Sunday, March 18, 2012 5:33 PM
-
Tuesday, March 27, 2012 4:48 PM
Hi JAJAYT1988,
The information you look for is I think about SQL.
Easy way is if you have SCOM 2007 R2 / SCOM 2012, you will not need database query. You can get the informations from SCOM Report Samples.
I would like to explain about VMM 2012.
You can query VMM Database through tbl_WLC_VMInstance and tbl_WLC_VObject
If you Access to VMM Database you can query as ;
SELECT Count(Name)AS VMTotalFROM [VMM2012].[dbo].[tbl_WLC_VObject]
It will give total VM included Templates.
SCOM Report is attached as Picture to give an idea.
If you dont have SCOM , you can do as query database.
Senior Virtualization Architect

