A number of folks have started to deploy Virtual Desktop solutions in earnest. Whether this is a solution from VMware, Citrix, or someone else – we often get asked how to drill down or provide a perspective on just the pieces of the virtual infrastructure supporting the Virtual Desktops (i.e. so we can understand CPU, memory, disk IO and network contention just on the subset supporting VDI)
So how can we identify the Virtual Desktops in our environment? One way is to look at the guest OS installed inside the VMs to infer whether this VM is a desktop (i.e. a desktop vs server OS). If you visit VMware’s supported OS page here, and filter by OS type of “Desktop” for ESXi5 – you get 38 individual OS results. In general, the majority are some flavor of Windows desktop OS (Windows XP, Windows 7 etc….) We can narrow these 38 individual OSes down into 8 categories and get:
MS-DOS (yes – it’s true!); Windows 3.1; Windows 7; Windows 95; Windows 98; Windows Vista; Windows XP; SUSE Linux Enterprise Desktop
So how can we find these type of desktop OS VMs in Virtualization Manager? We can leverage the power of search to find these VMs. If we look in the query builder inside the product, we can quickly find the the property “vm.guestFullName” that we’re looking for:
It’s worth noting the description listed with this property – this attribute gives a pretty accurate description of the guest OS as reported by VM Tools (which should really be installed in your virtual desktops anyhow). We can use the Editor Mode of the query builder to chain together (using “OR”) a list of the 8 OS categories we’re looking for, so something like:
vm.guestFullName:"MS-DOS" OR vm.guestFullName:"Windows 3.1" OR vm.guestFullName:"Windows 7" OR vm.guestFullName:"Windows 95" OR vm.guestFullName:"Windows 98" OR vm.guestFullName:"Windows Vista" OR vm.guestFullName:"Windows XP" OR vm.guestFullName:"Desktop"
which should match on VMs with a desktop OS property matching that particular phrase/string. Let’s try it out:
A quick mouse over on “hits” from search results looks like it is bringing up the right VMs. We can also look at a “facet” view (by clicking more->explore to the right of the search bar) to get a pie chart of how the desktop OS types break down in our environment.
One more quick concept – I am able to search “across” object relationships, so for example to find clusters that have VMs running Windows XP, I can do a cluster search for “cluster.vm.guestFullName:"Windows XP", similarly, to find datastores being used by Windows XP VMs, I can do a datastore search for “datastore.vm.guestFullName:"Windows XP”.
So let’s get back to our original premise – how can we use this search to give us a VDI perspective?
Since almost all of the content (widgets) on a Virtualization Manager dashboard are backed by a search, we can leverage the desktop OS search above, and across object relationships, to create widgets that focus only on the subset of the VMs supporting VDI.
Let’s take one example – the Cluster Memory Utilization widget on the default “Administrator” dashboard.
The standard search here is “* AND -cluster.memload.latest:0” (the second part filters out non zero results). If we leverage our new desktop OS search, we get:
* AND -cluster.memload.latest:0 AND (cluster.vm.guestFullName:"MS-DOS" OR cluster.vm.guestFullName:"Windows 3.1" OR cluster.vm.guestFullName:"Windows 7" OR cluster.vm.guestFullName:"Windows 95" OR cluster.vm.guestFullName:"Windows 98" OR cluster.vm.guestFullName:"Windows Vista" OR cluster.vm.guestFullName:"Windows XP" OR cluster.vm.guestFullName:"Desktop")
We put this search query into the widget configuration above, and we’ve got ourselves a Cluster memory utilization widget, just for our VDI clusters (or strictly speaking, the clusters containing VMs with a desktop OS).
If we go ahead and do this for a number of widgets, we could get a (slightly updated) version of the administrator dashboard for example, focused only on our VDI/desktop OS infrastructure.
We could also do the inverse, to find the VMs NOT running one of the above 8 types of desktop OS (i.e. a search for our server OS VMs essentially), we can use a search like:
vm.name:* NOT(vm.guestFullName:"MS-DOS" OR vm.guestFullName:"Windows 3.1" OR vm.guestFullName:"Windows 7" OR vm.guestFullName:"Windows 95" OR vm.guestFullName:"Windows 98" OR vm.guestFullName:"Windows Vista" OR vm.guestFullName:"Windows XP" OR vm.guestFullName:"Desktop")
You can download these dashboards from the community content exchange