Slow UI performance and high gnome-session CPU (#17014)

Discussions about using Linux guests in VirtualBox.
martinrist
Posts: 6
Joined: 8. Aug 2017, 13:20

Slow UI performance and high gnome-session CPU (#17014)

Post by martinrist »


[ModEdit; related ticket: #17014: Fedora Gnome slow UI performance]
Host OS: Windows 8.1 with Intel HD Graphics 4600
VirtualBox Version: 5.1.24 r117012
Guest OS: Ubuntu 16.04.2 LTS

I'm experiencing pathologically slow UI performance in my Ubuntu 16.04.2 guest. For example, from a fresh login, launching a Terminal window, then switching between full-screen and normal mode takes 10-20 seconds. Launching the GNOME 'Activities' view can take 30 seconds or more.

This works fine in VirtualBox (+ Guest Additions) 5.0.16, but appears to stop working in 5.0.18. I've installed a range of later 5.0.x and 5.1.x-series releases but none of these seem to resolve the issue.

The problem seems to be UI-related, since it's not noticeable from an SSH session connected to the guest.

There is noticeably high CPU utilisation (c. 40% - 50%) from the 'gnome-shell' process when doing these activities. Running `strace` when switching to the activities views shows a large number of `ioctl` calls with 5.0.18 that aren't present when running on 5.0.16.
Attachments
2017-08-08-11-38-48-bugreport.tgz
(252.92 KiB) Downloaded 146 times
vbox-5.0.18-strace.log.zip
(16.86 KiB) Downloaded 223 times
vbox-5.0.16-strace.log.zip
(7.61 KiB) Downloaded 340 times
Last edited by socratis on 10. Jan 2018, 10:00, edited 1 time in total.
Reason: Added ticket related information.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Slow UI performance and high gnome-session CPU

Post by mpack »

Please post a VM log file. With the VM fully shut down, right click and "Show Log" in the GUI, save "VBox.log" (no other file) to a zip, and attach the zip here.
martinrist
Posts: 6
Joined: 8. Aug 2017, 13:20

Re: Slow UI performance and high gnome-session CPU

Post by martinrist »

VBox.log file attached - this is the file that got packaged up into the 'bugreport.tgz' archive.
Attachments
VBox.log
(105.45 KiB) Downloaded 187 times
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Slow UI performance and high gnome-session CPU

Post by mpack »

I'm on Windows. I don't want to mess with tar.gz if I can avoid it. I did however ask you to zip the log.
00:00:12.578773 VMMDev: Guest Additions information report: Version 5.0.18 r106667 '5.0.18'
I would check and see if you still have the problem with current Guest Additions.

Also I see the following problem :-
00:00:01.678901 NumCPUs <integer> = 0x0000000000000006 (6)
...
00:00:02.165612 CPUM: Physical host cores: 4
Assigning cores you don't have - not a good idea at all. With a quad core host I'd assign 2 cores to the VM. VirtualBox is a simulation running on the host: it can't run well with -2 cores. FAQ: Cores vs Threads.
martinrist
Posts: 6
Joined: 8. Aug 2017, 13:20

Re: Slow UI performance and high gnome-session CPU

Post by martinrist »

I've just tried upgrading all the way to 5.1.24, and have reduced the number of cores assigned to the VM down to 2, as requested. Unfortunately, I'm still experiencing the same symptoms with 5.1.24. I've attached a zipped copy of the VM log file, extracted from the VirtualBox Manager GUI as per previous instructions.
Attachments
soepc-dev-env-test_default_1502184512656_81279-2017-08-09-10-21-47.zip
(28.81 KiB) Downloaded 150 times
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Slow UI performance and high gnome-session CPU

Post by mpack »

Ok, the next thing to try is to upgrade to VirtualBox 5.1.26, which was released earlier than normal precisely in order to fix a number of Linux guest regressions. However .26 still has problems related to AC'97. You can either disable audio, or you can try switching to Intel HD audio.
martinrist
Posts: 6
Joined: 8. Aug 2017, 13:20

Re: Slow UI performance and high gnome-session CPU

Post by martinrist »

I've just upgraded to 5.1.26, and unfortunately the same problem seems to be occurring. I've attached a revised exported VM log file to this reply.
Attachments
soepc-dev-env-test_default_1502184512656_81279-2017-08-09-14-42-28.zip
(28.45 KiB) Downloaded 149 times
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Slow UI performance and high gnome-session CPU

Post by mpack »

Did you change the audio settings? I'm still seeing AC'97 stuff in the log.

Otherwise, I'm out of suggestions. For all I know it isn't a VirtualBox problem at all, but some interaction with software installed in your guest. I suggest that you need to pin down which guest process is eating the CPU.
martinrist
Posts: 6
Joined: 8. Aug 2017, 13:20

Re: Slow UI performance and high gnome-session CPU

Post by martinrist »

I've now disabled audio, but that doesn't seem to have changed anything.

The high CPU utilisation seems to be in the 'gnome-session' process. When upgrading from VirtualBox 5.0.16 to 5.1.26 I first installed the new VirtualBox, then launched the VM and installed the updated Guest Additions. The problem only started appearing after upgrading Guest Additions to 5.1.26.

The issue goes away if I uninstall Guest Additions, and just use plain VirtualBox. Also, it doesn't seem to be present if I install and use the Unity Desktop in place of GNOME.

It looks like there's some kind of interaction between GNOME desktop and Guest Additions 5.1.26 which is causing the problem. I'm not sure if this sheds any light on the problem, but I'm happy to provide any additional diagnostic and troubleshooting information if that would be useful. I've attached the latest VM log (which should confirm audio disabling).
Attachments
soepc-dev-env-test_default_1502184512656_81279-2017-08-11-10-12-19.zip
(27.13 KiB) Downloaded 162 times
martinrist
Posts: 6
Joined: 8. Aug 2017, 13:20

Re: Slow UI performance and high gnome-session CPU

Post by martinrist »

For the benefit of anyone coming across this thread in the future, another user with similar symptoms has filed a bug report -> https://www.virtualbox.org/ticket/17014
JoergK
Posts: 30
Joined: 25. Aug 2017, 09:37

Re: Slow UI performance and high gnome-session CPU

Post by JoergK »

Hello,
I got the same problem in Virtualbox 5.2.0-118431 on a Win10 host with a RHEL 7.4 guest. I've attached a vbox.log to the ticket mentioned in the post above.
MuldeR
Posts: 27
Joined: 25. Aug 2014, 20:45

Re: Slow UI performance and high gnome-session CPU (#17014)

Post by MuldeR »

Just for the notes: Same problem exists with VirtualBox v5.2.12 running a "vanilla" Ubuntu 18.04 guest (on a Windows 10 host). UI initial works okay, but becomes unbearably slow after a short while...
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Slow UI performance and high gnome-session CPU (#17014)

Post by socratis »

@MuldeR
If you didn't notice, the ticket that this thread also talks about has the title: "Fedora Gnome slow UI performance".

So, I'm not sure how your Ubuntu 18.04 (which is brand new, not from last August) fits into the same category. Perhaps you should open a new thread instead of a "me too"? Because I have a feeling it's not a "me too" case.

Oh, and when you do, don't forget to post a ZIPPED VBox.log, as well as define "becomes unbearably slow" and "after a short while". Too vague of a statement that can mean different things to different people.
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
MuldeR
Posts: 27
Joined: 25. Aug 2014, 20:45

Re: Slow UI performance and high gnome-session CPU (#17014)

Post by MuldeR »

socratis wrote:If you didn't notice, the ticket that this thread also talks about has the title: "Fedora Gnome slow UI performance".
I did notice. But it's presumably the same problem. So you can read this as a "the problem is not limited to Fedora" notification.
socratis wrote:So, I'm not sure how your Ubuntu 18.04 (which is brand new, not from last August) fits into the same category. Perhaps you should open a new thread instead of a "me too"? Because I have a feeling it's not a "me too" case.
The problem first popped up for me with Genome 3 on Fedora. There was no such problem on older Ubuntu releases (e.g. 16.04). Ubuntu 18.04 switches to Gnome 3 desktop and voila!

Now the problem appears on Ubuntu too. Kind of "fits into the same category", I suppose :wink:
socratis wrote:Oh, and when you do, don't forget to post a ZIPPED VBox.log, as well as define "becomes unbearably slow" and "after a short while". Too vague of a statement that can mean different things to different people.
It means that right after I login to the Desktop. the system appears responsive, as it is supposed to be. But soon, e.g. after launching Firefox and browsing a web-site, the UI becomes extremely sluggish.

As the OP phrased it: „Launching the GNOME 'Activities' view can take 30 seconds or more“
Attachments
VBox.log.zip
(76.19 KiB) Downloaded 139 times
Terran
Posts: 1
Joined: 2. Jun 2018, 20:39

Re: Slow UI performance and high gnome-session CPU (#17014)

Post by Terran »

I'm having the same problem as MuldeR. I'm not at all an expert on Linux, so I can't provide much detail. I decided to start learning Linux using VBox only recently. I'm using an AMD Ryzen 1700 CPU, up-to-date Ubuntu 18.04 on Virtualbox v5.2.12 with GA installed. Everytime I turn on 3d acceleration on the VM the system runs fine but just for a few minutes. Then it starts getting all sluggish and unusable.
Attachments
VBox.zip
(43.93 KiB) Downloaded 158 times
Post Reply