VirtualBox

Ticket #6991 (closed defect: fixed)

Opened 4 years ago

Last modified 3 years ago

X11 servers experience extreme traffic from VB consoles -> fixed post 3.2. series

Reported by: UglyPercy Owned by:
Priority: major 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

comment:1 follow-up: ↓ 2 Changed 4 years ago by michael

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).

comment:2 in reply to: ↑ 1 Changed 4 years ago by UglyPercy

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 Changed 4 years ago by michael

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:4 Changed 4 years ago by michael

Any news here?

comment:5 Changed 4 years ago by michael

  • Summary changed from X11 servers experience extreme traffic from VB consoles to 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.

comment:6 Changed 3 years ago by frank

  • Status changed from new to closed
  • Resolution set to fixed

Please check VBox 4.0.

Note: See TracTickets for help on using tickets.

www.oracle.com
ContactPrivacy policyTerms of Use