#15324 reopened defect
Mouse pointer offset in Linux client => fixed in releases higher than 5.1.4
回報者: | meixner | 負責人: | |
---|---|---|---|
元件: | guest additions/x11/graphics | 版本: | VirtualBox 5.0.18 |
關鍵字: | Mouse pointer offset | 副本: | |
Guest type: | other | Host type: | other |
描述
After saving the running Linux (Mint Linux 17.1, 64 bit) to disk and reloading it, the mouse pointer shows an offset: The hot spot is not at the tip of the mouse pointer but located some pixels left of it. The Linux gues was running in full screen mode at that time.
Disabling full screen mode and resizing the window the pointer offset is fixed. The client is configured to adjust to the screen size. PS/2 emulation is used for the mouse.
Host is Windows 7 Professional 64 bit.
附加檔案 (6)
更動歷史 (64)
9 年 前 由 編輯
附檔: | 新增 VBox-Ubuntu-15.10.log |
---|
comment:2 9 年 前 由 編輯
I've experienced this as well. I have a Mint 17 host running a Ubuntu 14.04 guest, with 3D acceleration enabled. I use 4G of RAM in the guest and max out the video RAM at 128M. I installed from the installer virtualbox-5.0_5.0.18-106667~Ubuntu~trusty_amd64.deb
.
This was running fine on 5.0.16 (except for the longstanding 3D acceleration bug that causes crashes and prevents two 3D-enabled guests running in parallel) so I was very much looking forward to the Guest Utils changes that went into 5.0.17. Unfortunately the mouse offset bug made it difficult to use the machine, so I re-installed 5.0.16 (had to uninstall in Mint to do so).
As it happens I was having some high CPU usage issues in the guest during the transition (a particular website that causes Firefox's CPU usage to skyrocket) and my very-non-scientific-test was that they were somewhat worse in 5.0.18, and my poor ultrabook was reaching 70 deg Celcius temperatures and hard-crashing. Running Firefox and NetBeans together, which is fine in 5.0.16, was much slower in 5.0.18.
Feel free to ping me here to request any information you need to help debug this issue. Many thanks for looking into this, if you can.
comment:3 9 年 前 由 編輯
Hi have a similar problem: The offset of the "real mouse coordinates" are a bit shifted left and up. The problem appears in windowed mode with two screens activated.
One screen is fine (windowed and full screen). The problem does not appear, when the Guest is freshly started in windows mode, but after switching to full screen and back, it's there again.
When I resize the screen to the native monitor resolution, the problem does not appear (but not auto adjusted, with scroll bars). When I resize the Windows Virtual Box Window and maximize it again, it works again, too.
Host Windows 10 VB 5.0.18, Client is Ubuntu 14.04.1 with LXDE desktop installed, Additions 5.0.18_106667.
I also tried out the default window manager and compiz, works fine on those. It might be a window-resize/refresh-with-two-monitors bug on LXDE?
Thanks a lot
comment:4 9 年 前 由 編輯
I'm having the issue as well, this is what I can contribute:
Host: Windows 10 Pro 64-bit
Guest: Kali Linux (based on Debian Jessie)
Guest kernel: Linux 4.4.5, Linux 4.4.6, Linux 4.5.1, Linux 4.5.2
Guest DE: LXDE
Same result using each input type (PS/2 mouse, USB tablet, USB multi-touch tablet).
It all started in a test build of 5.0.17. I haven't run into the issue in 5.0.16. It's currently still present in test build VirtualBox-5.0.19-106880-Win.exe.
As previous commenter has said the issue disappears completely when the VM window is maximized to the screen. When un-maximizing it (making it resizable) there is about 1 second before the cursor position shifts. Weirdly, if I stretch the window to be as tall as my screen, passing the taskbar, it creates scrollbars because I guess the OS is downsizing the height because it was too tall but the VM window doesn't see the vertical resize response from windows happen I guess, creating scroll bars. The scroll bars also seem to prevent the cursor position bug from happening. Go scroll bars!
When bringing the cursor outside the guest window, it resets the position and fixes it BUT only for the first 4 pixels from the left of the screen. Once you leave the first 4 pixels on the left, the issue returns. As most of my work is outside that err 4 pixel range, it's been a nightmare. :)
跟進: 6 9 comment:5 9 年 前 由 編輯
Could you confirm if this issue only happens with VMs restored from a saved state (or a snapshot) or does this also happen if the guest is normally booted?
comment:6 9 年 前 由 編輯
Replying to frank:
Could you confirm if this issue only happens with VMs restored from a saved state (or a snapshot) or does this also happen if the guest is normally booted?
I've never used snapshots or saved states before, always normally booted and have the issue. It's definitely related to the height of the VM window somehow.
comment:7 9 年 前 由 編輯
As far as I know there are two issues with the 5.0.18 Guest Additions:
- The hot spot of the mouse cursor is not correctly set. As a result, the user has to click slightly more rightwards+downwards to hit a button/scrollbar etc. in the guest. The OP if this ticket wrote that this often happens after loading from a saved state. Switching to fullscreen and back seems to fix this problem.
- Sometimes there are two mouse cursors, the guest cursor is located slightly more left+up than the host cursor. The offset here has probably the same reason as 1) but of course there shouldn't be two mouse cursors.
comment:8 9 年 前 由 編輯
This issue is not related to the use of snapshots or saved states. I experience the problem when booting a (Linux Ubuntu) VM to a resizable window. I use VirtualBox 5.0.18 r106667. The guest VM has the latest guest additions installed. Problem does not occur in 5.0.16.
comment:9 9 年 前 由 編輯
Replying to frank:
Could you confirm if this issue only happens with VMs restored from a saved state (or a snapshot) or does this also happen if the guest is normally booted?
I also saw it sometimes happen with VMs not restored from a saved state but I cannot reliably reproduce it.
comment:10 9 年 前 由 編輯
Very reproducible and highly annoying. I can make a video if you like. What's interesting is that there are two different offsets depending where and how i move the mouse into the window. You can actually see it jump. Definitely do not see this on Windows guests.
Linux host:
- VirtualBox 5.0.18 r106667
- Fedora 22 4.4.6-201.fc22.x86_64 #1 SMP Wed Mar 30 18:30:16 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
Linux guest:
- Guest additions 5.0.18r106667
- Fedora 23 4.4.7-300.fc23.x86_64 #1 SMP Wed Apr 13 02:52:52 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
跟進: 12 comment:11 9 年 前 由 編輯
I have upgraded to 5.0.20 r106931 and so far have not been able to reproduce.
跟進: 13 comment:12 9 年 前 由 編輯
comment:13 9 年 前 由 編輯
Replying to frank:
Sorry, but it's unlikely that this is fixed. I suspect the problem in the Guest Additions and I'm not aware of related fixes.
You're right; it has reared its ugly head.
跟進: 15 comment:14 9 年 前 由 編輯
Thanks for the comments everyone. I've upgraded the virtual machine described in my earlier post (Mint 16 host, Ubuntu 14.04 guest) to 5.0.20 and initially the login screen behaved very strangely. It resized to 800x600-ish despite being on an 1920x1080 screen in fullsize mode. Moving the cursor past the horizontal halfway point caused it to jump past the furthest horizontal point of the virtual screen size.
However, a second reboot fixed this, and now the earlier offset problem is gone. I'm surprised this is not thought to be fixed, as in 5.0.18 the bug exhibited itself immediately, and now in 5.0.20 it does not. @r2d3, can you shed more light on how this bug manifests itself?
I can confirm that the bug appeared in 5.0.18 from cold VM boot, not a machine restore, and it seems to be fixed for me in the newer version, again from cold VM boot. If the bug comes back again I will update again here and will explain how to replicate it.
跟進: 16 comment:15 9 年 前 由 編輯
Replying to halfer:
Thanks for the comments everyone. I've upgraded the virtual machine described in my earlier post (Mint 16 host, Ubuntu 14.04 guest) to 5.0.20 and initially the login screen behaved very strangely. It resized to 800x600-ish despite being on an 1920x1080 screen in fullsize mode. Moving the cursor past the horizontal halfway point caused it to jump past the furthest horizontal point of the virtual screen size.
This sounds like it could be a different issue from the one we are experiencing.
However, a second reboot fixed this, and now the earlier offset problem is gone. I'm surprised this is not thought to be fixed, as in 5.0.18 the bug exhibited itself immediately, and now in 5.0.20 it does not. @r2d3, can you shed more light on how this bug manifests itself?
I can confirm that the bug appeared in 5.0.18 from cold VM boot, not a machine restore, and it seems to be fixed for me in the newer version, again from cold VM boot. If the bug comes back again I will update again here and will explain how to replicate it.
You should be able to reproduce the bug, causing the shift, by simply resizing the VM window smaller, either horizontally or vertically. You can fix the positioning bug by making the VM window bigger.
The cursor position shift happens when the guest automatically resizes after the VM window is resized negatively, either horizontally or vertically.
It is fixed by doing the complete opposite.
Happy to have finally found the deciding factor on whether the bug appears or not, and how to reproduce it!
comment:16 9 年 前 由 編輯
Replying to jcadduono:
This sounds like it [a login display issue] could be a different issue from the one we are experiencing.
Oh yes, I agree - it was just in the category of "strange display problem" and I thought I would mention it in case the two issues had the same underlying cause.
The cursor position shift happens when the guest automatically resizes after the VM window is resized negatively, either horizontally or vertically.
I've now been able to reproduce the main bug here also. I've found that a save+restore in full-screen mode will bring up the machine with a mouse offset. A simple toggle of full-screen (i.e. off first and then on again) resolves it.
It seems that from cold boot, my VM is fine.
跟進: 18 19 23 comment:17 9 年 前 由 編輯
The latest 5.0 Additions test build<1> might fix this.
<1> Testbuilds
comment:18 9 年 前 由 編輯
Replying to michael:
The latest 5.0 Additions test build<1> might fix this.
<1> Testbuilds
Using Guest Additions 107136 I cannot reproduce the issue at all. Appears to be fixed. Thanks a lot!
Out of curiosity can you point to the version control commit that fixes this? :)
comment:19 9 年 前 由 編輯
Replying to michael:
The latest 5.0 Additions test build<1> might fix this.
<1> Testbuilds
I've been running it all day and have not seen it. Thanks!
comment:20 9 年 前 由 編輯
摘要: | Mouse pointer offset in Linux client → Mouse pointer offset in Linux client => Fixed in SVN |
---|
comment:21 9 年 前 由 編輯
works for me, too (ubuntu 14.04 with lxde: one scree, two screens, full screen and windows mode)! thanks!
comment:22 8 年 前 由 編輯
I have also been experiencing this annoying offset in a 'Fedora release 20 (Heisenbug)' guest, for the last 2 or 3 releases of VB. I'm now running 5.0.20. I only get the problem with xfce, and not Cinnamon (or maybe I have just not used Cinnamon long enough)
It seems I'm now getting a correct pointer location, after resizing several times and rebooting my VM. I hope the fix will quickly be pushed in the official release!
comment:23 8 年 前 由 編輯
Replying to michael:
The latest 5.0 Additions test build<1> might fix this.
<1> Testbuilds
Was having the same issue where actual cursor click position would be offset to top left by a few pixels from the displayed position.
Would happen when coming back to VB guest window (Ubuntu 14) after having it minimized in Windows 7 taskbar. Resizing the guest window would normalize the position, but quickly had become an annoying extra step.
Can confirm that using test build of Guest Additions (i.e. VBoxGuestAdditions_5.0.21-107986.iso) has resolved the issue. No need to install a test build of Virtual Box, just the additions.
Thanks michael!
comment:24 8 年 前 由 編輯
I'm using VirtualBox 5.0.18 (from ubuntu repo) with 5.0.20 guest additions installed (manually downloaded because of comment 18) and have a horizontal shift of ~8 pixels while the vertical is ok, with older additions the shift was bigger. Both guest and host are Xubuntu 16.04 (xfce)
comment:26 8 年 前 由 編輯
狀態: | closed → reopened |
---|---|
處理結果: | fixed |
I am still having this issue, with V. 5.0.22, both app and guest additions, linux host (ubuntu 16.04), linux guest (ubuntu 16.04).
I think i started to experience it when i upgraded the guest from ubuntu 15.10 to 16.04 (but may be coincidential that also upgrader VB version)
comment:27 8 年 前 由 編輯
元件: | other → guest additions/x11/graphics |
---|
Did you reinstall the Additions when you upgraded the guest? Could you please attach a log file for the machine, as well as /var/log/Xorg.0.log, the output of dmesg and the output of lsmod, all three from the guest? And I assume you are using Additions installed from the VirtualBox Additions installer, not provided by the distribution?
comment:28 8 年 前 由 編輯
I am able to consistently reproduce the issue (for the most part) on several of my configurations. It is rather annoying. It always revolves around the host screensaver and/or lock screen.
Symptom: Mouse cursor is a few pixels to the left and up.
Hosts: Windows 10 x64 or Xubuntu 14.04
Guests: Xubuntu 14.04 and Xubuntu 16.04 (Latest guest additions installed)
Virtual Box: Version 5.0.24 r108355
Configuration Details: Dual monitor, guest window is maximized one monitor (not full screen). Guest use of lock screen or screensaver does not affect the issue. It occurs with guest auto-login, guest lock screen, or guest screensaver. Auto-resize guest display is ENABLED.
Reproduce steps:
- Lock host screen or allow screensaver to appear on host.
- Login to host again, mouse cursor is off a few pixels. Easiest to test by trying to place cursor in a text document.
- Sometimes the problem is reversed. The mouse cursor is normal at full screen, but resizing causes it to be off in the new size.
Resolution:
Resize client. After client desktop automatically resizes to new window size, restore to full screen. Pixel problem is resolved.
Remarks:
Despite how or when it occurs, the resolution always works. Resize the guest, wait for it auto-adjust, resize to desired dimensions, wait again, continue work.
comment:29 8 年 前 由 編輯
cpm, Zifik, please provide at least one VBox.log file for such a VM session where you experience the mouse pointer offset.
comment:30 8 年 前 由 編輯
I was not able to reproduce this based on the steps given above. I suggest that the people seeing this should work together to try to find out more about it. One suggestion: try stopping the VBoxClient --draganddrop process in the guest to see if that makes a difference. And please provide the logs which I requested in comment:27.
comment:31 8 年 前 由 編輯
I can confirm this issue as well.
I'm now on VirtualBox 5.1.2, but having this issue since at least 5.0.20.
Stopping or restarting the drag and drop process did not help.
I'll attach the requested logs.
8 年 前 由 編輯
附檔: | 新增 Xorg.0.log |
---|
8 年 前 由 編輯
comment:32 8 年 前 由 編輯
i can confirm the issue, but a little more detailed. When cursor is a "pointer" or "auto" everything is fine. But whenever the cursor is "text" it still uses the upper left corner, which leads to this buggy behaviour. I have seen this in phpstorm in Virtualbox 5.1.2 on a linux client. Actually the behaviour was gone after one update, but yesterday it mystically just came back.
comment:33 8 年 前 由 編輯
but now its gone after a reboot of the VM. It probably happens sometimes whenever i save the state of the VM and later recover it.
comment:34 8 年 前 由 編輯
I'm afraid this is likely to need some investigation. The issue is definitely fixed, so chances are that there is some specific situation (saving and restoring often tend to have interesting effects) where the fix fails to work. But since I will not have time to search for that situation someone will need to provide me with a reasonably quick way to reproduce and test it if it is to be solved.
comment:35 8 年 前 由 編輯
I restarted my machine and can now confirm that the problem has no relation to saving and restoring the virtual machine state, at least for my case. It does seem like it has something to do with inactivity, but I'm not sure it is exactly the host screensaver triggering like Zifik said.
The fact is that the cursor seem to be slightly misplaced after some idle time on my PC.
Resizing the window back and forth usually fixes it, but sometimes I need to go back and forth through fullscreen mode.
Michael, is there anything I can do to help you find a resonably quick way to reproduce and test if the problem is solved?
跟進: 37 comment:36 8 年 前 由 編輯
For a start trying to find a way to reproduce it reliably (as in "it happens exactly when I do this", not "it seems to happen in this situation but maybe not") yourself. That will still not be enough if I cannot do the same, but it would be some progress.
comment:37 8 年 前 由 編輯
Replying to michael:
For a start trying to find a way to reproduce it reliably (as in "it happens exactly when I do this", not "it seems to happen in this situation but maybe not") yourself. That will still not be enough if I cannot do the same, but it would be some progress.
Sounds like a plan. I can't do this during weekdays because I use the VM to work, but I'll try to take a better look this weekend to see if I can find an easy and fixed way to reproduce the problem. Thanks for the help so far.
跟進: 39 comment:38 8 年 前 由 編輯
This happens for me too
- I downloaded the latest VirtualBox, and the latest Xubuntu 16.10
- never used saved states
- when I minimize virtual box and then re-open it, the mouse hotspot is up+left
- when I resize the guest, and then re-maximize it, it's temporarily fixed
comment:39 8 年 前 由 編輯
This problem regularly afflicts me as well. PcChip is spot on.
Replying to PcChip:
This happens for me too
- I downloaded the latest VirtualBox, and the latest Xubuntu 16.10
- never used saved states
- when I minimize virtual box and then re-open it, the mouse hotspot is up+left
- when I resize the guest, and then re-maximize it, it's temporarily fixed
comment:40 8 年 前 由 編輯
Same problem here: Windows 7 host Kubuntu 16.04.1 guest VirtualBox 5.1.4
Are there any workarounds or patches planned? The version is unusuable as it is and the resizing trick does not work for me.
comment:41 8 年 前 由 編輯
This bug still happens with VirtualBox-5.1.5-110394.
Windows 7 host. Kubuntu 16.04.1 with Plasma 5.6.5 via PPA.
comment:42 8 年 前 由 編輯
To get more logging information, you could try making the following changes to the file /usr/src/vboxguest-5.1.[...]/vboxvideo/vbox_mode.c on the guest:
After the line
copy_cursor_image(src, dst, width, height, mask_size);
add a line reading
printk("CURSOR_SET: hot_x=%u, hot_y=%u\n", hot_x, hot_y);
After the lines
if (hot_x == vbox->cursor_hot_x && hot_y == vbox->cursor_hot_y) return 0;
add lines reading:
printk("CURSOR: vbox->cursor_hot_x=%u, vbox->cursor_hot_y=%u, hot_x=%u, hot_y=%u, host_x=%u, host_y=%u, x=%u, y=%u, crtc->x=%u, crtc->y=%u\n", vbox->cursor_hot_x, vbox->cursor_hot_y, hot_x, hot_y, host_x, host_y, x, y, crtc->x, crtc->y);
Both of these changes are close to the end of the file. Then rebuild the driver by running
/sbin/rcvboxadd setup
as root. After rebooting the guest you should get lots of additional logging in the guest system log ("dmesg | less") starting with "CURSOR" which will show how the cursor hot spot is calculated.
nopaste: you can also revert the change I asked you to make to /var/lib/VBoxGuestAdditions/config on IRC and change BUILD_TYPE back to 'release' there.
comment:43 8 年 前 由 編輯
The output of "dmesg" immediately after the problem occurs might be interesting. If the output contains no "CURSOR" lines at all, the output of "modinfo vboxvideo" and "lsmod | grep vboxvideo" would be interesting.
comment:44 8 年 前 由 編輯
I modified the source files and ran the setup.
dmesg | less shows no lines starting with CURSOR.
The output of modinfo vboxvideo
filename: /lib/modules/4.4.0-36-generic/kernel/ubuntu/vbox/vboxvideo/vboxvideo.ko version: 5.0.18_Ubuntu license: GPL and additional rights description: Oracle VM VirtualBox Graphics Card author: Oracle Corporation srcversion: 13C89163828486B6D203AF8 alias: pci:v000080EEd0000BEEFsv*sd*bc*sc*i* depends: drm,drm_kms_helper,ttm,vboxguest,syscopyarea,sysfillrect,sysimgblt intree: Y vermagic: 4.4.0-36-generic SMP mod_unload modversions parm: modeset:Disable/Enable modesetting (int)
The output of lsmod | grep vboxvideo
vboxvideo 53248 2 ttm 94208 1 vboxvideo drm_kms_helper 147456 1 vboxvideo drm 364544 5 ttm,drm_kms_helper,vboxvideo syscopyarea 16384 2 drm_kms_helper,vboxvideo sysfillrect 16384 2 drm_kms_helper,vboxvideo sysimgblt 16384 2 drm_kms_helper,vboxvideo vboxguest 286720 6 vboxsf,vboxvideo
comment:45 8 年 前 由 編輯
That explains why you are still seeing this problem - you are not using our driver, but the version provided by Ubuntu, which of course still contains the bug. It seems my attempts to force the guest system to use our version are not succeeding.
comment:48 8 年 前 由 編輯
摘要: | Mouse pointer offset in Linux client => Fixed in SVN → Mouse pointer offset in Linux client => fixed in releases higher than 5.1.4 |
---|
Thank you for the confirmation.
跟進: 50 comment:49 8 年 前 由 編輯
I can confirm the issue is fixed on my side as well
Host Windows 7 64
VirtualBox 5.1.4r110228
Guest Debian 8.1 running i3 on X11
Running in Multi-Monitor-Mode. Guest is running full-screen over two host monitors
comment:50 8 年 前 由 編輯
Replying to syracus:
I can confirm the issue is fixed on my side as well
Host Windows 7 64
VirtualBox 5.1.4r110228
Guest Debian 8.1 running i3 on X11
Running in Multi-Monitor-Mode. Guest is running full-screen over two host monitors
Which Guest Additions are you using?
comment:53 8 年 前 由 編輯
This bug happens with VirtualBox 5.1.6 if you still have the guest additions < 5.1.6, i.e. 5.1.4 installed. Did you have 5.1.6 guest additions installed when you encountered this error?
comment:54 8 年 前 由 編輯
狀態: | closed → reopened |
---|---|
處理結果: | fixed |
This bug is still current as of 5.1.8 in the Mac version.
Host: MacOS Sierra in a Macbook Pro 2015, no extra monitors.
Guest: Linux Mint 18 with 5.1.8 guest additions
Virtualbox 5.1.8 r111374
Running full-screen mode in HiDPI.
Only some pointers are affected. Crosshairs are ok, as is the normal arrow-shaped pointer. Text pointers are offset.
comment:55 8 年 前 由 編輯
狀態: | reopened → closed |
---|---|
處理結果: | → fixed |
Mike, I wonder if you are not seeing a different issue: the one referred to in ticket #15707 and fixed by the latest test builds (in the host application, not the Additions, see comment 13 on that ticket). I will close this ticket again, and if the test build does not fix your issue you should probably open a new one.
comment:56 8 年 前 由 編輯
I'm running a Xubuntu 16.04 VM in VirtualBox 5.1.14r112924 on Windows 10 host and I still see the problem in windowed mode. Before 5.1.14 I saw it only when I had 2 virtual screens enabled, now I see it even if I have only one. It's a 100% reproducible.
comment:57 8 年 前 由 編輯
I have VirtualBox Version 5.1.14 r112924 (Qt5.6.2) and Host is Windows 7 Professional 64 bit. Guest is Ubuntu 16.04 with latest addons and I see this problem still in windowed mode.
Replying to meixner:
After saving the running Linux (Mint Linux 17.1, 64 bit) to disk and reloading it, the mouse pointer shows an offset: The hot spot is not at the tip of the mouse pointer but located some pixels left of it. The Linux gues was running in full screen mode at that time.
Disabling full screen mode and resizing the window the pointer offset is fixed. The client is configured to adjust to the screen size. PS/2 emulation is used for the mouse.
Host is Windows 7 Professional 64 bit.
comment:58 7 年 前 由 編輯
狀態: | closed → reopened |
---|---|
處理結果: | fixed |
I am running VB 5.2.0 r118431 (Qt5.6.2) on Windows 7 for an Xubuntu 16.04 guest OS. When I boot the VM, the cursor is correctly aligned, but after a day or two (I run it uninterrupted all week except for pauses), the cursor drifts down and to the right.
It's seriously annoying. I don't feel I should have to reboot to get the cursor realigned.
Same here. I am running VBox 1.0.18r106667 on Ubuntu 15.10 host. Guest is Debian 8.4 Jessie. In guest:
Issue was not reproducible w/ 5.0.0-101573~Ubuntu~trusty (and GAs from it) package. That mean, I previously was running Ubuntu 14.?? w/ 5.0.0-101573~Ubuntu~trusty and then upgraded to Ubuntu 15.10 and installed virtualbox-5.0_5.0.18-106667~Ubuntu~wily_amd64.deb on top of it. Hope this helps. Attaching VBox.log as well.