Friday, October 12, 2012

Preventing VMware View users from accidentally ejecting USB devices

For those who may have come across my previous posts:

Disappearing network adapter with VMware View 5.0 and vSphere 5.0

… would know that I recently ran into a strange incident where a user accidentally ejects the network adapter within their virtual desktop and subsequently gets cut off from their desktop because the virtual network adapter simply vanishes from the virtual machine’s properties in vSphere.  While I have yet to find a method of apply this to multiple virtual machines, one of the fixes available is to manually edit the properties of the virtual machine’s settings in vSphere or the VMX file.  The following is the KB that provides the instructions to do it:

I went through the process with the vSphere client earlier this morning so I’ll include it into this post in case someone is looking for something more visual:

Shutdown the virtual desktop and edit the settings of the virtual machine:


Within the virtual machine’s properties, click on the Options tab, then General (under Advanced):


Click on the Configuration Parameters… button:


Within the configuration parameters window, click on the Add Row button:


In the Name field, type in devices.hotplug and in the Value field, type in false:


Exit out of the properties and start the desktop.  You’ll notice that when you connect to the desktop with the View client, the USB icon in the system tray will no longer be displayed:



The problem with this solution is that it would be too much manual labor to perform when there is more than 10 virtual desktops in the environment.  I’ve tried multiple ways to make the change in the master template but haven’t had any luck with getting the configuration to stick so I’ll update this post when I find a better solution that scales better with large environments.

No comments: