Controlling Hyper-V VMs in Virtual Machine Connection over TS/Remote Desktop without a mouse


With Hyper-V RC0 now available, [Update: 26th June 2008. Hyper-V RTM is now available. RC0 is pre-release software] the ideal solution for controlling VMs remotely is to use the Hyper-V management tools from another Windows Server 2008 machine, or from Vista SP1 – the Vista tools being available shortly. However, many people like to use a Remote Desktop (mstsc) session to the Hyper-V parent partition, and use Virtual Machine Connection in that session. In Hyper-V beta, mouse control in this scenario is erratic and effectively unusable (Ben has more information here). For that reason, we now explicitly block mouse capturing in Hyper-V RC0 when using Virtual Machine Connection over a TS session and display a message that the Mouse is not captured in the Remote Desktop session.

0

Maybe I’ve been using computers for way too long, but clearly from email’s I been receiving, many people struggle to use Windows without a mouse. Once you get the hang of it, I promise, it really isn’t that hard. The secret sauce is knowing a few key presses or how to get to a command prompt. Many times, a command prompt is sufficient, so let’s start with one way. (Obviously this also assumes you are not using a Server Core installation). Take a look at the toolbar and menu in Virtual Machine Connection. You can either click the icon on the far left, or select Ctrl-Alt-Delete from the Action menu.

1

From here, you can hit Tab 4 times to select "Start Task Manager" and hit Enter.

2

By default, Windows Task Manager is always on top of other windows. While that sometimes isn’t a bad thing, once you start a command prompt, it can get in the way. So, you can use Options/Always On Top to change that behaviour. You do that by Alt+O to select Options, then just hit Enter as Always On Top is the first action on the menu.

3

Getting to a command prompt AND being able to see it’s contents is now pretty simple. From Task Manager, select File (Alt+F) and New Task (Enter), type cmd and hit Enter.

4

But what if you aren’t logged on as local administrator, and want a command prompt run as administrator? Now you need a few more of those "secret sauce" keys. The first step is being able to get to the start menu. For that, Alt-Home is your friend. The command prompt is by default pinned to the start menu.

5

So you can press the arrow up key a few times. But that still doesn’t get round the case where you want to run it as an administrator. This is where the next key sequence, Shift-F10, comes in. Move up to the Command Prompt item using up-arrow and press Shift-F10. This displays the context menu, the equivalent of right-clicking on something. You then have the option of "Run as administrator"

6

What if I wanted to get to the drop-down menu in a command prompt (the one at the top-left) to maximize it or use Edit/Mark and Edit/Paste? Well for that, you need Alt-Delete.

6a
What if I had a few applications running, and I want to switch between them. The answer is the keys Alt+PageUp and Alt+PageDown. These are the equivalent to Alt-Tab and Alt-ShiftTab in a regular machine.

7

With that set of keyboard knowledge, plus remembering Tab and Shift-Tab to change focus from one control to another in a window, you can pretty much navigate Windows in a VM in it’s entirety.Of course, Hyper-V has another trick up it’s sleeve which also helps. Under Hyper-V settings on Hyper-V Manager, you can choose where to redirect Windows key combinations. The default setting though is for they keys to be used on the physical computer.

8

Usually with the above knowledge, you can get far enough to install service packs where needed, and the integration services for Hyper-V so that you get mouse control back again. Happy keyboarding. Time to throw that mouse away? I challenge you ๐Ÿ˜‰

Cheers,
John.


Comments (36)

  1. Anonymous says:

    Hyper-V HW & SW requirement: http://technet.microsoft.com/en-us/library/cc816844.aspx Hyper-V RTM

  2. Anonymous says:

    With the RTM release of Hyper-V just around the corner, I thought it would be a good idea to re-visit

  3. Anonymous says:

    ้€™ไธ€็ฏ‡้ƒจ่ฝๆ ผ่ฆๅ„ไฝ้€ฒ่กŒๅฐŽ่ฎ€ไป‹็ดน็š„ๆ˜ฏ Controlling Hyper-V VMs in Virtual Machine Connection over TS/Remote Desktop without

  4. Kaj Jensen says:

    I found out, that my problem controlling the mouse was because I had not installed RC1 on the Server 2008 VM’s as well…

  5. Kaj Jensen says:

    You write: "For that reason, we now explicitly block mouse capturing in Hyper-V RC0 when using Virtual Machine Connection over a TS session and display a message that the Mouse is not captured in the Remote Desktop session."

    I am not using any TS session (in fact the TS service is disabled on my server), -but Dell DRAC (hardware, that works even if the computer is shut down) to remote comtrol my server. This worked perfectly with the Beta version of Hyper-V, but after installing RC1, I am not able to take control of the mouse in any VM sessions (using DRAC). I dont get the message you mention, and in the status line i get the usual message, that i can press CTRL+ALT+LeftArrow to release control of the mouse. Howver the mouse doesnt move …. Why is that. How have you disabled mouse movement ?

    When I try to install the Integration Components on a newly created VM (server 2008) I get the message that it is already installed…

  6. Brendon – Is there a specific reason you need to use TS to the Hyper-V machine to install a guest OS? if you configure remote management (eg using HVRemote for easiest configuration) or use the console of the Hyper-V machine, you will be able to use the mouse inside the guest operating system during OS installation. Once you install the Integration Services in the VM, you will no longer be in captured mouse mode.

    Thanks,

    John.

  7. Chris – can you explain a little more about your environment and what you’re trying to do. Workgroup or domain joined (client and server), routers/firewalls in between, the IP settings of the machine you are trying to connect to etc.

    Thanks,

    John.

  8. Malloc – if the Integration Services are installed, all is good.

    Cheers,

    John.

  9. Chris – I got your email, but am getting a delivery timeout on my response. Can you email me again please – not sure if you put a typo in your email address.

    Thanks,

    John.

  10. Anonymous says:

    Excellent i have bookmarked this article now.

  11. Kaj – I don’t have a machine with DRAC to hand, only the HP iLO BMC equivalent, but will track a dell box down in our labs. I can only assume that the DRAC remote console application is using RDP under the covers and that is what is being detected.

    For the IC’s on a server 2008 VM, are you running the MSU update in the VM, or using actions/insert integration services setup disk from the virtual machine connection menu? It should be the first one.

    Thanks,

    John.

  12. Chris Kinsman says:

    The management tools for Vista SP1 don’t support using a FQDN for accessing the hyperv box.  They assume a flat NetBios naming convention so now I am stuck…

  13. Kaj Jensen says:

    I was using Dell DRAC (separate hardware / network card inside the server) to control my server (with W2K8).

    Before I installed RC1 I was able to use this tool to remote control VM’s on my server, -without any mouse problems at all !

    Now, since installing RC1, I cannot take control of my mouse anymore inside a VM.

    You mention that "we now explicitly block mouse capturing in Hyper-V RC0 when using Virtual Machine Connection over a TS session ". However this is not a TS session (as far as I define it ….)

    How can it be, that I am not able to take control now ?

  14. Andrew Somervell says:

    +1 to not being able to use DRAC.

    In final could mouse control over RDP please be an option?

    While I agree that management should probably be done from another 2K8 Server or Vista machine with the MMC snapin… Right now I just want to get a bloody VM up and running and with keys like the Start key not being passed through thats a mission!

    Other than that, stoked with the whole platform to date, nice work ๐Ÿ™‚

  15. malloc says:

    So even with RTM you can’t use the mouse in a TS session?  That just seems backwards to me.

  16. malloc says:

    I just read though the linked posts and went over this one again and saw that after Integrations the mouse will work as jhoward said.  Whew!

    Thanks for clearing that up.  I got to the point with my test box that I saw I couldn’t get the mouse to work wih RDP this week and decided to give up until RTM. Now I"ll go hook up a KVM to the parent box to get Integration working and be set.

  17. pankaj says:

    I have windows Vista sp1 and win-2008 with Hyper-V. I am not able to manage the Hyper-V machines through MSTC using mouse. With out mouse controll, the use  of MSTC to the Hyper-V machines gives no meaning?? Is there anyway to use mouse ??? No alternate like get used to keyboard or command line controll..

    Regards

    Pankaj

  18. Jon Robertson says:

    Ok, this just sucks.  Please pardon my french.  I feel like typing so many four letter words it is NOT funny.

    I AM a keyboard guy.  I have been for 27 YEARS.  I don’t touch the mouse if I can help it.

    I’m migrating from Virtual Server 2005 R2 SP1 to Hyper-V.  And in terms of remote control, NOTHING beats VMRC.  This new Virtual Machine Connection thing in Hyper-V sucks big time.

    So I have a VHD from VS2005 with additions uninstalled.  I copy the VHD to Hyper-V and create a new machine.  I start the machine.  I go to Install Integrations.  I tell it OK to update HAL and reboot.  When rebooting, the Find New Hardware wizard appears, then the Integrations install dialog appears.  I read from several places that I have to cancel the Find New Hardware wizard before the Integrations will install.

    But guess what!  I can’t!  Mouse won’t capture (at least it would capture without Additions in every version of Virtual PC/Server).  Alt-Tab doesn’t switch between applications in the VM (like VMRC does), it switches between apps in the host.  Windows key and CTRL-ESC go to host rather than VM.  Alt-Space and Alt-Hypen go to host rather than VM.  Nothing I try lets me get rid of the wizard.  I go Googling and come across this post, which actually helped…

    Click the CAD button, hit T for Task Manager, use arrow keys to select the Find New Hardware "application" (probably have to ctrl-tab to that page), then use the keyboard shortcut to switch to the application (ctrl-s?).

    FINALLY I can cancel the darn wizard.

    Would somebody PLEASE create a version of VMRC that has all the functionality that VS 2005 R2 SP1 VMRC.exe had but is able to connect to Hyper-V machines.

    Not to mention that I very, very, often remotely manage my VMs (not Virtual Server, but the actual VMs) using VMRC.exe.  At 440K and no install, just throw it on my USB drive and I can access my VMs from anywhere.

    Why in the world has Microsoft crippled Hyper-V remote connectivity so much compared to Virtual Server ?!?!?!?

  19. Bart Simpson says:

    WOW…GREAT JOB GUYS

    Yet another reason to just use Linux

  20. Jens K. Rasmussen says:

    In the start the mouse din’t work for me eigther.

    The i startet to configure the hyper-v server up without a mouse, What a Pain !

    Then, when i was about to install the virtuel network trough the Panel, Action – Insert Integration servises setup disk.

    The Hyper-v Server should restart, after it again was ready for login, the mouse Worked !!!

    Just wanted to pass this greatfull adwise out, and hope it will work for the rest of you with the same problem ๐Ÿ™‚

  21. joe otero says:

    This hap hazzard approach to deploying an incomplete product is yet another reason Microsoft doesn’t get it. I just installed Windows Server 2008 and configured my first Hyper V machine and when I try to get into the guest OS to finish configure I am denied the mouse. A mouse is an essential piece of equipment if you expect to use any version of Windows (except for DOS). Why would Microsoft push out a product like Hyper V without the if the mouse? I’ve work in command line systems before (UNIX and Cisco IOS) but they are designed to be used by a keyboard only, Windows is not designed like this. I guess my choice is clear go with VMware.

  22. TJ Downes says:

    Good article, and works in most cases. However, one of the MS developers who worked on the Windows Home Server 2008 installer forgot to allow you to tab to certain options, thereby eliminating any workaround. Sucks

  23. name says:

    "Maybe I’ve been using computers for way too long, but clearly from email’s I been receiving, many people struggle to use Windows without a mouse."

    lulwut?

  24. Brendon says:

    What a joke.

    This is highly disappointing.  I think it’s something that should have been sorted before it even hit beta.  

    I gave up on building my first hyper-v VM because I refuse to use a bandaid workaround to such a obvious problem.  It is a total PITA.

  25. Brendon says:

    My Hyper-v server is a headless box, with no monitor.  People would also have problems getting physical access in some colocation environments.  

    The reason I made the comments above was due to frustration.  I had already done the HVremote setup (both machines in a workgroup), but was annoyed that it was necessary and had too much stuff open to do a reboot at that time.  I regularly use Vmware ESX , Microsoft virtual server 2005 and vmware server.  In those products, you can rely on the simplest of things like the mouse just working.

    Installing the integration services doesn’t help while you’re still doing the build.

    Cheers,

    Brendon.

  26. Dmitry Blokhin says:

    John, yes, I may give you an example of situation where mouse is ABSOLUTELY needed. When install Windows XP as guest OS, after second or third reboot it stops with dialog telling about some screen resolution ajustments. At this time there are no task manager, Windows button and other stuff mentioned above. Integration services disk aren’t recognized at this moment as well. And the worst thing – this is a system MODAL dialog, and it is NOT ACTIVE. So there are no keyboard shortcut to change focus to this dialog’s "OK" button…

  27. Kevin says:

    @Bart Simpson

    Just because _you_ can’t make it work doesn’t mean it doesn’t do it…

    @Dmitry

    if you set the hyperv settings to pass through windows key combos (like alt-tab) you can very easily ok it…

    @lots of other people:

    You seem to be missing the point that this is only disabled when you rdp into the host os… if you’re running the vmc from your local workstation as you should be, its no issue… granted it’s unfortunate that mouse doesn’t universally work, but from a macro infrastructure scale this model works.

  28. bingojed says:

    This is dumb!  I’m trying to set up XP for testing, on a Hyper-V server in another state, and I’m certainly capable of using keyboard shortcuts – BUT there’s a point at which XP goes to a black screen and says "To Improve the appearance of visual elements, Windows will automatically adjust your screen resolution" with just an OK box.  There is no keyboard shortcut that will press that OK button – no tabs, space, alt-this-that-other-thing that I’ve found to click on the OK button.  Nothing.

    This is before I can install the Integration components.  Didn’t anyone at Microsoft test this?  No other VM solution I’ve ever seen has this kind of limitation.

  29. Jeff25 says:

    Just installed Windows Xp in Hyper-V. At the dreaded "To Improve the appearance of visual elements, Windows will automatically adjust your screen resolution" dialog, press ALT + PAGE UP (equivalent of ALT + TAB) to move the focus to the dialog box. Dismiss it with an ENTER (equivalent of a click on the OK button). Use TAB and SHIFT + TAB to move the focus around on the next few dialog boxes.

  30. sebus says:

    And try to do this with booting to Hiren’s BootCd 9.x & try to use something

    While the keyboard works fine in the menu, once the mouse DOS driver loads, there is no more mouse OR keyboards (at least on my PS2 mouse/keyboard via USB converter)

    sebus

  31. Andrew says:

    For those of you trying to get past the Windows XP screen resolution dialog box you’ll need to goto View – Full Screen mode in your remote machine connection before you can use Alt + Page up etc.

  32. vmware says:

    Problem solved! User VMware, its free and it works!

  33. Akuma says:

    This totally sucks.

    I'm using a Windows XP to connect to my servers remotelly. Those servers are in a remote Datacenter and in one of them I installed Hyper-V Server 2008 R2.

    Kevin and other MS "clever" people that got to this: How is supposed for me to control the mouse to install a guest or to use a Live ISO?

    Answer: YOU CAN'T.

    Why?

    2 laughable reasons:

    1.- Because using the physical server to install the guest is not possible in Hyper-V Server.

    2.- Because installing the Hyper-V Remote Management is NOT possible in Windows XP or Windows Server 2003 (but even if it could be done, that would means a lot of GPO's, firewall touch and internal company policy to get it working).

    3.- Because installing the Integration Services is not possible in a Live ISO (reboot required).

    Do don't understand that this is a BUG that you try to defend as know feature? This can't be considered other thing that a stupid move with the excuse of: "it's erratic when allowed". To that my answer is "then just fix it, because it's needed and other thing to that is just a joke".

    Take note: VirtualBox, all VMWare software, Xen, even those from Microsoft (Virtual PC and Virtual Server) allow to use the mouse in a guest using a RDP session.

  34. Tim Wiser says:

    I'm more than happy with controlling Windows using keystrokes.  I do that pretty much all day and have done for years.  However, at the moment I'm faced with a situation where the StorageCraft recovery bootable CD appears to have a bug in it where one of the dialog windows cannot be accessed using the keyboard so I'm having to leave the comfort of my office and walk all the way over to the server room, log into it, click a mouse a couple of times, and then return to the office again.  Bit of a faff, no?  Erratic behaviour would be better than none at all. As someone else pointed out, installation of the Integration Services kit isn't an option if you're working outside the OS.

  35. Without Satori, mouse work in Linux Guest if connect to it from Windows _directly_ :

    blogs.technet.com/…/controlling-vms-under-hyper-v-without-the-mouse.aspx

  36. Just a guy says:

    When doing remote desktop to your Hyper-V and are loading an OS that doesn't support the Synthetic mouse…  Gotta use keyboard short-cut, some of which are shared with RDP…

    Solution:  OSK!   On Screen Keyboard ๐Ÿ˜‰   it's annoying, it sucks but it works.

    I wouldn't want to run this with an OS that has no support at all for the synthetic mouse, most cases you'd have to run VNC after the install or some other tool.  But during install it allows you to survive the ordeal !

    my 2 cents.