Unable to move or resize guest Window

Discussions related to using VirtualBox on Linux hosts.
Particle
Posts: 7
Joined: 20. Mar 2008, 16:29

Re: Unable to move or resize guest Window

Post by Particle »

I'm the Debian testing (sid) guy again. Reporting some more experimental results.

Test 1:
I tried continuing with the MATE DE but replacing its Marco WM with Compiz. I didn't have any luck though. None of my windows were drawn with borders or controls, so I had to abort that test.

Test 2:
I also tried the Cinnamon DE with its default Muffin WM. No change in behavior. Virtualbox guest windows became frozen in place within seconds of starting.

Notes:
  • I don't have xbindkeys installed, so I couldn't experiment with that as Ultradrom suggested.
  • It's worth pointing out that Marco, Muffin, and Xfwm4 are all GTK based. I'm not sure if that is the common factor.
  • I've tried both lightdm and gdm3 display managers.
Test 3:
I installed lxqt so that I could try a desktop environment and window manager built on QT instead of GTK. My VirtualBox guest windows didn't freeze in place right away, but they later did. Lots of things in the desktop environment were crashing though, so I can't be certain if that is it. If it is, the question becomes what in GTK isn't playing nicely with the VirtualBox interface.
Last edited by Particle on 13. Jun 2018, 03:30, edited 1 time in total.
skuda
Posts: 16
Joined: 20. Dec 2008, 02:32

Re: Unable to move or resize guest Window

Post by skuda »

I tried the "kill xbindkeys workaround" and it fixes the problem for me as well, thanks!
KPearson
Posts: 6
Joined: 7. Aug 2017, 18:53

Re: Unable to move or resize guest Window

Post by KPearson »

FYI, I've not resolved this on Linux Mint 18.3 (work laptop) though it works fine on my home laptop. Both are upgrades using the Upgrade to 18.3 option in the Update Manager when I was on a previous version. I do use xbindkeys on both to set my mouse buttons 8 and 9 to open terminator in single-wide (8) and double-wide (9) terminals. Killing it may be okay, as long as I can restart it and keep its functionality.

Okay, just tested and it works. If xbindkeys is running, no moving VM window. How in the world did you figure that out?

As I mentioned, I'm using the QT version (VBox for any platform) so I can host work cloud VMs.

But also as I mentioned, if I shade the VM, I can move it anywhere; for me, problem solved. Kind of...

I'm not sure why I can't move the VM around when it's not shaded, but until it's fixed, I'll shade away.

Note to Linux noobs. Shading is when you double-click the window title bar and the VM (or any other app) appears to roll up into the title bar. I change my DE so double-clicking doesn't push the window to full screen. <soapbox>I actually detest that feature. That's what the maximize button is for.</soapbox>
Ultradrom
Posts: 2
Joined: 8. Jun 2018, 00:52

Re: Unable to move or resize guest Window

Post by Ultradrom »

After all, imho, I derived the formula for the window stuck problem:
XBINDKEYS, X11, ?WAYLAND!, ?QT?, ?GTK?, !your_WindowManager, VirtualBox.
KPearson wrote:Okay, just tested and it works. If xbindkeys is running, no moving VM window. How in the world did you figure that out?
Good question:) Yep, xbindkeys is too far from VirtualBox...
I am install fresh Xubuntu18.04, VBox windows move ok.
After installing some packages and add some configs - VBox windows stuck.
Found this forum thread - no solution. I assumed that I am closer to the bug than others.
Then just reinstall fresh Xubuntu18.04 and repeat my log step by step.
Bingo! After customize ".xbindkeysrc" - VBox windows stuck again.
So, "it's" near the xbindkeys. Publish investigation results.
I spent several hours, but I hope this will save a lot of time and nerves for the world.
Particle wrote:with Compiz. I didn't have any luck though. None of my windows were drawn with borders or controls, so I had to abort that test.
Two ideas for you:
1) "How to disable Wayland and enable Xorg display server on Ubuntu 18.04 Bionic Beaver Linux"
https://linuxconfig.org/how-to-disable- ... aver-linux
2) Also you can try Compiz with Wayland enabled and/or without it.
To enable window decorations "borders or controls" in Compiz:
Install Compiz WITH PLUGINS: $ sudo apt-get install compiz compiz-plugins compizconfig-settings-manager
run "CompizConfig Settings Manager": $ ccsm
enable plugin "Window Decoration" in "Effects" section,
enable plugins "Move Window" and "Resize Window" in "Window Management" section.
?enable plugins "Composite", "Gnome Compatibility" and "OpenGL" in "General" section
start compiz: $ compiz --replace
...to revert back to your previous WindowManager simple reboot or : $ YOUR_WINDOW_MANAGER --replace

P.S. Maybe related info:
1) "Due to a mistake, Qt Wayland was made the default platform plugin on gnome-shell sessions in Qt 5.11.
The combination of gnome-shell and Qt Wayland still results in too many bugs,
and hence Qt Wayland was removed from the Qt Creator pre-release builds altogether,
at least until Qt Wayland is made opt-in again."
http://blog.qt.io/blog/2018/05/29/whats ... rm-plugin/

2) "Teamviewer 13. Ubuntu 18.04 Faulty Wayland detection and logging in."
https://community.teamviewer.com/t5/Lin ... td-p/33983
KPearson
Posts: 6
Joined: 7. Aug 2017, 18:53

Re: Unable to move or resize guest Window

Post by KPearson »

skuda wrote:Same problem here using Arch Linux.
@Kpearson, did you finally find the culprit?
No, I didn't. Sad day . . .
As to the following post, see below:
FixVer1: kill process "xbindkeys", start VM, move window is ok.
FixVer2: comment ALL uncommented lines in "~/.xbindkeysrc", kill & restart process "xbindkeys", start VM, move window is ok.
FixVer3: (before: make cfg backup!) reset cfg of xbindkeys by the command "xbindkeys --defaults > ~/.xbindkeysrc", kill & restart process "xbindkeys", start VM, move window is ok.
FixVer4: while VM window is started: select any other inactive window, now you can move or resize inactive VM window by borders and title.
FixVer5: while VM window is started: "Shade" VM window, now you can move the window, un-Shade VM window.
FixVer6: (crazy) switch from xfwm4 to Compiz by command "compiz --replace", now you can move or resize VM window.
I killed xbindkeys and could move the window. Once. Since then it isn't working to kill xbindkeys, so back to shading the window, which always works.

I've not tried the other xbindkeys options, and can't justify the waste of time they would be since I have customized settings in the rc file for controlling my mouse.

Selecting an inactive window won't cut it on my setup because I use Sloppy Focus, which I won't do without. I can barely stand using MS Windows since they added that feature--weakly.

I don't plan to use Compiz. It's too bloated and has too many issues with the proprietary nVidia drivers I get from the Mint repos...

So as I said, I'm back to shading the window, moving it, then unshading.

I'm going to keep watching this thread, however, because I believe someone here will get a real solution at some point, else the VBox developers will get wind of this and make a change (unlikely).
KPearson
Posts: 6
Joined: 7. Aug 2017, 18:53

Re: Unable to move or resize guest Window

Post by KPearson »

After a little work, I noticed that when I am starting up the VM, I can move and resize it any way I want to, so before it finished loading, I resized it to the size I want, then moved it to the position on the screen I want it.

What's interesting is that once it's running, I can no longer do any of that. That's been the issue for me.

Since I use xbindkeys for mouse functions, I don't like leaving it off, however testing that didn't prove helpful for me either.

But, I wonder if it's because I'm also using DevilsPie2? I should probably test that since xbindkeys was an unyielding rabbit hole. I don't know when I'll have time. I don't have time to add these comments during work, and since that's the system I'm having problems with, I only deal with it while working...

If I can take the time, I'll update this thread and let you know if also disabling, or only disabling, devilspie2 will help.
SpahZ
Posts: 31
Joined: 26. Nov 2015, 21:21

Re: Unable to move or resize guest Window

Post by SpahZ »

Particle . . your resolution . . "Resolution: 2560x1440"
Multiple monitors ?

Seems the geoX11 code was dorked a while back
. . 5.0.2 and earlier work properly,,

Stripe windows bug remains in 5.0.24
viewtopic.php?f=7&t=78607
Auto-resize snaps back to first physical monitor
viewtopic.php?f=7&t=74790
VirtualBox switches permanently to a small stripe window
viewtopic.php?f=7&t=74683

The bug will manifest a bit differently depending on how big X/Y
the screen is, and how much force/hack they do to cover over
the botched geometry.
Alanbr
Posts: 2
Joined: 27. Sep 2018, 19:05

Re: Unable to move or resize guest Window

Post by Alanbr »

I had the same problem on Min 19 xfce

My solution: Settings --> desktop settings --> select xfwm4 + Compton instead xfwm4 + composite.

AlanBR
maravento
Posts: 2
Joined: 24. Nov 2018, 00:32

Re: Unable to move or resize guest Window

Post by maravento »

same problem in Ubuntu Mate 18.04.1 x 64 kernel 4.15.0-39-generic. Change Compton to Compiz (or other) does not solve the problem. Even clicking on the vm window of virtualbox blocks mate-panel (and need to run killall mate-panel to return to normal). It does not work to make "downgrade" of virtualbox or "upgrade" of the linux kernel.
See this possible solution: [offset link deleted by mod]
Alanbr
Posts: 2
Joined: 27. Sep 2018, 19:05

Re: Unable to move or resize guest Window

Post by Alanbr »

My solution:
At virtual box main window go to:

File -> Preferences -> input -> Virtualbox manager.
Uncheck the "auto Capture keyboard" checkbox.
Tested on gnome 3.22 / Debian 9.
RobertLugg
Posts: 3
Joined: 15. Jan 2019, 23:47

Re: Unable to move or resize guest Window

Post by RobertLugg »

I believe i have the same problem. I don't know if my workaround offers any hints.
VirtualBox 6 on Windows 7
centos7 minimal + openbox + lightdm client.

After login everything works fine. Open up gnome-terminal. Still things are OK.
If I click 'in' the terminal (where the command line is), the mouse actions 'inside' the gnome-terminal work, but nothing outside that app. I cannot resize or select that window. I cannot right-click on the desktop, which normally opens the context menu. The mouse moves normally otherwise.

Workaround: After being "stuck", I select Help...About on the menu within gnome-terminal. The about dialog appears. I click on 'Close'. Now, everything is back to normal. I can resize windows and right click on the desktop to get my context menu.

Workaround2 (edit): Another way to get the mouse working again is to right-click in the application window to call up the context menu. That's enough to get things working again (until it happens again)

Any thoughts on how to get the mouse working?

(whoops: I realize that I'm posting in the "Linux Hosts" section where I have a MS Windows 7 host) I'm happy to move this question over there, but this thread seemed the best.)
toracat
Posts: 87
Joined: 8. Dec 2018, 02:39
Primary OS: Linux other
VBox Version: PUEL
Guest OSses: RHEL CentOS Scientific Linux
Location: California, USA
Contact:

Re: Unable to move or resize guest Window

Post by toracat »

@RobertLugg

You were hit by a known kernel bug. Please see Mouse only usable within single application after mouse click on RHEL 7.6 (#18124).
Beginning is easy – Continuing is hard.
RobertLugg
Posts: 3
Joined: 15. Jan 2019, 23:47

Re: Unable to move or resize guest Window

Post by RobertLugg »

@toracat re: postby toracat » 16. Jan 2019, 11:42

The workaround suggested by @rconde01 » 11. Jan 2019, 23:10
Another trick if you get stuck on Redhat:

Ctrl-Alt-F2 (switches to a secondary screen)
Ctrl-Alt-F1 (switches back)
worked for me. It not only fixed the issue immediately but I also couldn't get "locked out" again. In other words, at least for that session it was "Fixed". It continued to work after logout/login.

If it crops back up I'll try your kernel patch. Thanks for the response
Last edited by socratis on 17. Jan 2019, 22:37, edited 1 time in total.
Reason: Added missing URLs.
toracat
Posts: 87
Joined: 8. Dec 2018, 02:39
Primary OS: Linux other
VBox Version: PUEL
Guest OSses: RHEL CentOS Scientific Linux
Location: California, USA
Contact:

Re: Unable to move or resize guest Window

Post by toracat »

@RobertLugg

Please monitor that forum thread. I will update it as soon as I see a new kernel with the fix.
Beginning is easy – Continuing is hard.
robocat
Posts: 7
Joined: 29. Oct 2009, 11:58
Primary OS: Ubuntu 8.04
VBox Version: PUEL
Guest OSses: Windows XP Pro

Re: Unable to move or resize guest Window

Post by robocat »

If reader has a problem with Ubuntu guest hanging when trying to resize a window. This helped me: https://askubuntu.com/questions/1035410 ... er-1111826
Locked