Opened 15 years ago
Closed 14 years ago
#6991 closed defect (fixed)
X11 servers experience extreme traffic from VB consoles -> fixed post 3.2. series
Reported by: | UglyPercy | Owned by: | |
---|---|---|---|
Component: | GUI | Version: | VirtualBox 3.2.4 |
Keywords: | x11 console traffic lag | Cc: | |
Guest type: | Linux | Host type: | Linux |
Description
When I started working with VB, I observed extreme lag in interacting with my CentOS 4 console via a Cygwin X11 server. After boot, for example, after the login prompt was printed, if I typed "root", none of the characters would even echo for a minute or two. This was a mystery until I noticed that this only happened when I was working from home via cable modem, using a VPN connection to work. I then observed that, during the post-boot freeze period, my network input was saturated at 1.1 MB/s.
I soon traced this problem to the fact that VB is emulating a VGA video adapter, with a hard-coded refresh rate of 50 Hz. Apparently, during the boot process, the scrolling (perhaps so-called smooth scrolling is to blame) of the normal messages backlogged my X11 display to the point where it took a couple of minutes to catch up.
I am using VB OSE, so I don't believe I can easily use VPN/RDP, but even if I can, this problem is a bad one -- it can give new users a very bad impression of VB VM performance, if they use X11 to a remote machine over a non-fast connection. My solution was to edit "src/VBox/Main/DisplayImpl.cpp" to change the refresh rate to 1 FPS, but perhaps there are better solutions available, such as connecting to X in some different mode. If all else fails, perhaps the default refresh rate could be lowered to, say, 10 Hz, and an entry placed in the VB global preferences to call attention to this value, and its complex tradeoff between X11 traffic volume and responsiveness.
Change History (6)
follow-up: 2 comment:1 by , 15 years ago
comment:2 by , 14 years ago
Thanks Michael -- that sounds like a much better solution. Any chance that this (or a Refresh Rate field in the VB preferences) would become part of the next official release?
comment:3 by , 14 years ago
If you test it and find that it solves your issue then there is a good chance of it. It would be good to know though whether it does help.
comment:5 by , 14 years ago
Summary: | X11 servers experience extreme traffic from VB consoles → X11 servers experience extreme traffic from VB consoles -> fixed post 3.2. series |
---|
We committed this to the development tree. I will assume that it fixes the issue.
You might try the following to see if it makes a difference: in
src/VBox/Frontends/VirtualBox/src/runtime/UIMachineView.cpp
replace the call to "viewport()->repaint" around line 872 (inside the "case VBoxDefs::RepaintEventType:" block) by "viewport()->update". update is a method that schedules repaints for later (specifically the next time the application enters the main Qt event loop) and merges all repaints done at one time into one (see http://doc.trolltech.com/4.6/qwidget.html#update).