How to Contact Us

callback Request Callback
enquiry form Enquiry Form
email info@help4it.co.uk
telephone 0800 043 4448
fax 0845 257 4449
address London HQ
61 Queen Street
London EC4R 1AF

Inside Track!

Inside information directly from help4IT technicians

Jan 21
2009

Create a desktop shortcut to connect to an ESX VM console

Posted by: Tom Finnis

So we've got a nice fat ESX server running in our training lab with 20 XP VMs installed on it - and a bunch of barely IT literate users each with a desktop PC that is fully locked down so there is no chance of them screwing anything up. We want to give them access to the XP VMs so they can screw those up instead, e.g. see how much malware they can acquire in 10 minutes of unprotected Internet browsing. That means we can't allow any sort of network connection between our nice safe desktops and these VMs, otherwise we're going to get all that malware coming back into our network, which rules out the obvious candidates like RDP or VNC. What we can do though is connect to the VM consoles as our ESX server is all properly vLANned so the VMs are on one network with an Internet connection but our ESX server and desktops are on a completely separate network.

So how do we get those users connected to those consoles?

 

The secret is something called "vmware-vmrc", its actually a standard component of VMware Server 2; if you've ever used it on a Windows PC its the IE/Firefox plugin which allows you to access your VM consoles. VMware Server 2 is even nice enough to include an option to create a desktop shortcut that you can just double-click to load your VM interface. However we dont want to be using VMware Server because it runs on top of Windows (or Linux for that matter) and so there's a pretty hefty performance hit compared to ESX which is a proper hypervisor.

The nice thing is you can download and install the VMRC component without having to get the rest of VMServer2- these nice people http://support.minicom.com/KVMnet/Tools/VMwareVMRC.exe have put it on their website for us. In case you want to do it the Linux way the method is the same from now on, but you'll just have to find a copy of the installer yourself.

Once you've downloaded and started VMwareVMRC.exe remember where you tell it to install itself as it won't create a Start Menu group - I stuck with the standard location for consistency though. Browse to the folder it creates and you'll find a whole bunch of files, you need them but don't worry about what they do. Just right-click the vmware-vmrc.exe file and "Create Shortcut", then drag that to your desktop.

Now you need to find out a couple of important settings, first the IP address (or host name) of your ESX server and secondly the location of the VM on the server. The first is easy, but to find the second on your ESX server right-click the VM and "Edit Settings", then the "options" tab - look on the right and copy the "VM Config File" path:

Now go back to the VMRC shortcut you put on the desktop and open its properties, at the end of the "Target" path you need to add the following:

 -h 192.168.1.59 -"[datastore2] vistatest/vistatest.vmx" -X

Obviously change the IP and VM config file location details to match yours but your shortcut should end up like this:

Note the -X at the end, it tells VMRC to open the VM full screen but you can remove it if you want.

Click "OK" to close, then double-click to run and you should get a logon prompt for your VM, enter your usual credentials and you will get your VM desktop.

Now in our particular example we have 20 desktops and 20 VMs we want to connect them to so we'll have to install VMRC on each desktop, but provided we use a sensible naming scheme for the VMs its not going to be hard to copy the shortcut across and just edit the Target line. Alternatively it should be hard to write a short script which will just prompt the user for the VM name and then insert that into the command line to run VMRC, its just coding isnt my thing - please feel free to contribute!

Comments (2)Add Comment
0
it supervisor
written by tj warren, March 16, 2009
Trend Micro reported on this file as potential malware.
Tom Finnis
Potential Malware
written by Tom Finnis, March 16, 2009
I originally scanned the file with NOD and AVG which didnt report any problems, and I haven't had any reports of malware from other users. However if you are concerned you can download VMware Server 2.0 and extract the file from that installation instead.

Write comment

busy