VirtualBox

Opened 15 years ago

Last modified 9 years ago

#2613 closed defect

Host key (ctrl) sometimes gets stuck down in Windows guest — at Version 10

Reported by: myxiplx Owned by:
Component: other Version: VirtualBox 2.0.4
Keywords: ctrl host key stuck Cc:
Guest type: Windows Host type: Linux

Description (last modified by Michael Thayer)

Not all the time, but regularly enough to be a nuisance, the host key gets stuck down within the guest after it's been used to free up the mouse. Does VirtualBox always send the "key-up" message to the guest after the host key has been pressed?

I'm running VirtualBox full screen on my second monitor, and often hit ctrl so that I can leave the virtual machine running, but free the mouse so I can continue working on my primary screen.

After doing this, about a quarter of the time, I go back to the guest to find the control key stuck down. It means typing is impossible, and unlocking a machine with your password is a nuisance until you spot what is going on. Tapping the left control key on the keyboard does seem to free it up again.

I also run the VMware Infrastructure Client within this virtual machine, and that requires the use of Ctrl+Alt to free the mouse from its client windows. A couple of times now that has wound up locking the mouse and keyboard within VirtualBox when I come back to it, and it appears to coincide with times the control key has gotten stuck down. I'm reporting this here instead of as a separate bug as I think it's just another symptom of the same problem.

For now I've changed my host key to the Scroll Lock button, that appears to be a useful workaround for now.

Change History (10)

comment:1 by Aren Cambre, 12 years ago

I'm running into the same problem, 3 years later. :-) Has there been any progress on this?

comment:2 by Reuben Thomas, 12 years ago

I have noticed the same problem with Alt getting stuck down in the guest after using Alt+Tab in seamless mode with keyboard capture switched off, so that the host always gets the keystroke.

Using Ubuntu 12.04 host, Windows 7 guest.

It can be cleared by pressing Alt again in the guest, but it makes seamless mode use unreliable.

comment:3 by Reuben Thomas, 12 years ago

I can confirm the same problem in fullscreen mode (again with keyboard capture switched off).

comment:4 by Bo, 12 years ago

This has happened to me since about the 4.1.16 release. I run Ubuntu as my base system and use Windows 7 as the VM. Windows 7 behaves pretty well. The toggling from Windows back to Ubuntu is not as smooth as it used to be and the workspaces now behave oddly in 4.1.22. I wish at had stayed with the earlier variations of release 4. Still, a great product and thanks for the hard work.

comment:5 by B. J. Potter, 12 years ago

I have seen this problem using an Arch linux host and a Windows XP guest. The only way I could solve this was to pause and unpause the host machine. After that, the problem went away!

comment:6 by Dtremblay, 12 years ago

Same problem here. Host Windows 7 and Guest Windows XP. The key up message seems to get lost somewhere.

comment:7 by Roger Pack, 11 years ago

Dunno if it's the same problem, but with Windows 7 + Linux guest, sometimes when I "leave" the guest, the ctrl key for windows thinks it's down when it's not! (often enough to be annoying...) thanks! -r

comment:8 by mosimu, 11 years ago

This sounds like Sticky Keys. The following might help:

Open the Control Panel on Windows 7 host > Ease of Access > "Change how your keyboard works" > "Set up Sticky Keys"

Uncheck the option "Lock modifier keys when pressed twice in a row."

When your Ctrl or Alt key is stuck on the host, you should be able to unstick by holding down both Ctrl and Alt at the same time, then releasing. This works because of the other option you see in Control Panel, "Turn off Sticky Keys when two keys are pressed at once."

comment:9 by Reuben Thomas, 11 years ago

It's not StickyKeys, at least in my case (I'm not even using a Windows host).

Last edited 11 years ago by Reuben Thomas (previous) (diff)

comment:10 by Michael Thayer, 11 years ago

Description: modified (diff)

If it is not sticky keys on the host then you should be able to make it go away (I am not suggesting that this is a solution to the problem) using the command line command "VBoxManage controlvm keyboardputscancode <code>", where "code" is the hexadecimal scan code value (PS/2 scan code that is) of the key which is stuck. This page<1> has a list of hexadecimal scan codes for all standard keyboard keys.

<1> http://www.win.tue.nl/~aeb/linux/kbd/scancodes-1.html

Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use