gnome-volume-control-applet takes up to 40% cpu

Bug #400820 reported by Susan Cragin
68
This bug affects 11 people
Affects Status Importance Assigned to Milestone
GNOME media utilities
Unknown
Critical
gnome-media (Ubuntu)
Fix Released
Low
Ubuntu Desktop Bugs

Bug Description

During the last couple of days, my processor occasionally seems to be running on overtime. When I open the system monitor, I find that the gnome-volume-control-applet is taking up to 40% of my CPU.

I haven't even opened the volume control. I don't know how it gets open.

My sound system and applications are as follows.
I have purged pulseaudio and installed esound. I run no programs that require audio other than through wine (Dragon NaturallySpeaking).

In addition, I occasionally surf the internet, and sometimes visit sites that play short audio clips. I think the problem might arise after I visit those sites.

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

You say you purged Pulseaudio - but the new applet doesn't work without Pulseaudio anyway.

Perhaps you could report this upstream to http://bugzilla.gnome.org/ , as you're experiencing the issue.

Thanks

affects: ubuntu → gnome-media (Ubuntu)
Changed in gnome-media (Ubuntu):
importance: Undecided → Low
status: New → Incomplete
Revision history for this message
dino99 (9d9) wrote :

Karmic testing.

Same thing for me here:

- cpu used over 40 % by gnome-volume-control-applet.

- looking at .xsession-errors: this file is oversized too : over 25 Mio after only 10 minutes & still full filled. can't open it because too big i suppose.

- user.log: i see "oem-desktop last message repeated 43645 times"

- to be able to open .xession-errors, i reboot & then shut down to generate a smaller file. Ok , here is interesting reasons and explanations:
          1) ** (gnome-volume-control-applet:3345): WARNING **: Connection failed, reconnecting...
          2) (polkit-gnome-authentication-agent-1:3327): GLib-GIO-WARNING **: g_simple_async_result_complete() called from outside main loop!
          3) (gedit:4398): Gtk-CRITICAL **: gtk_progress_set_percentage: assertion `percentage >= 0 && percentage <= 1.0' failed

I've not found others messages but have no sound too since this problem appear.

Let me know if you need specific output.

Revision history for this message
dino99 (9d9) wrote : apport-collect data

Architecture: i386
DistroRelease: Ubuntu 9.10
NonfreeKernelModules: nvidia
Package: gnome-applets 2.27.3-0ubuntu2
PackageArchitecture: i386
ProcEnviron:
 SHELL=/bin/bash
 LANG=fr_FR.UTF-8
ProcVersionSignature: Ubuntu 2.6.31-3.19-generic
Uname: Linux 2.6.31-3-generic i686
UserGroups: adm admin cdrom dialout lpadmin plugdev sambashare

Revision history for this message
dino99 (9d9) wrote :
Changed in gnome-media (Ubuntu):
status: Incomplete → New
tags: added: apport-collected
Revision history for this message
dino99 (9d9) wrote :

That seem related too : cant open "System --> Preferences --> Sound", no response.

Revision history for this message
dino99 (9d9) wrote :

Some more findings:

Htop shown me too that pulseaudio use ~15 % of cpu. So, in a console i run : sudo dpkg-reconfigure pulseaudio. This command stop & restart pulseaudio.

And the good surprise now: there is no more over eating cpu activity:
 -no more trouble with previous gnome-volume-control-applet
 - nor with pulseaudio
 - and i can now open system/preferences/sound

So, it appear that it's clearly a problem of pulseaudio or of one of its dependencies

Revision history for this message
dino99 (9d9) wrote : apport-collect data

Architecture: i386
AudioDevicesInUse: Error: command ['fuser', '-v', '/dev/dsp', '/dev/snd/by-path', '/dev/snd/controlC0', '/dev/snd/pcmC0D0p', '/dev/snd/pcmC0D2c', '/dev/snd/pcmC0D1p', '/dev/snd/pcmC0D0c', '/dev/snd/pcmC0D1c', '/dev/snd/seq', '/dev/snd/timer', '/dev/sequencer2', '/dev/sequencer'] failed with exit code 1:
Card0.Amixer.info:
 Card hw:0 'Intel'/'HDA Intel at 0xfebfc000 irq 19'
   Mixer name : 'Realtek ALC882'
   Components : 'HDA:10ec0882,1043e601,00100101'
   Controls : 44
   Simple ctrls : 25
DistroRelease: Ubuntu 9.10
NonfreeKernelModules: nvidia
Package: pulseaudio 1:0.9.15-4ubuntu2
PackageArchitecture: i386
ProcEnviron:
 SHELL=/bin/bash
 LANG=fr_FR.UTF-8
ProcVersionSignature: Ubuntu 2.6.31-3.19-generic
Uname: Linux 2.6.31-3-generic i686
UserGroups: adm admin cdrom dialout lpadmin plugdev sambashare
mtime.conffile..etc.init.d.pulseaudio: 2009-07-17T10:54:19

Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
dino99 (9d9) wrote :

I recovered sound and audacious run fine .

Revision history for this message
dino99 (9d9) wrote :

The bad things now:
this problem still exist one reboot later: same troubles & i have to run "sudo dpkg-reconfigure pulseaudio" & then all is ok.

Revision history for this message
dino99 (9d9) wrote :

Googling around:
https://bugzilla.redhat.com/show_bug.cgi?id=489142
I have the same problem too

Revision history for this message
dino99 (9d9) wrote : apport-collect data

Architecture: i386
DistroRelease: Ubuntu 9.10
NonfreeKernelModules: nvidia
Package: gnome-media 2.27.4-0ubuntu2
PackageArchitecture: i386
ProcEnviron:
 SHELL=/bin/bash
 LANG=fr_FR.UTF-8
ProcVersionSignature: Ubuntu 2.6.31-3.19-generic
Uname: Linux 2.6.31-3-generic i686
UserGroups: adm admin cdrom dialout lpadmin plugdev sambashare

Revision history for this message
dino99 (9d9) wrote :
Revision history for this message
Sebastien Bacher (seb128) wrote :

The issue is an upstream one and it would be nice if somebody having it could send the bug the to the people writting the software (https://wiki.ubuntu.com/Bugs/Upstream/GNOME)

Changed in gnome-media (Ubuntu):
assignee: nobody → Ubuntu Desktop Bugs (desktop-bugs)
Revision history for this message
Sebastien Bacher (seb128) wrote :

dino you could subscribe to a bug when you comment, and sending 20 emails as you did is spamming people subscribed

Revision history for this message
Susan Cragin (susancragin) wrote :

After a check of synaptic, I have noticed that removing, and even purging pulseaudio does not remove many of its component parts, which parts continue to function, uselessly spinning the wheels looking for pulseaudio.
Gnome-volume-control applet is only one of them.
One of the sound apps that is called up in firefox clearly tries to "grab" pulsuaudio, and starts the volume-control applet running.
In firefox, when the application says "this media requires a plug-in" the suggested plug-in is likely to require pulse, because the system does not check whether pulse is there or not.
Clearly, removing pulseaudio is tricky and requires its own page of documentation, at the very least.
The good situation would be to have the --purge command remove ALL related programs that grab it, like gnome-volume-control.

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

Susan - gnome-volume-control-applet contains a change in this release to try and reconnect to Pulseaudio if it becomes disconnected. This is to fix bug 319443, and is most likely what is causing your issue.

As you're experiencing the issue, it would be great if you could report this upstream to http://bugzilla.gnome.org/

Thanks

Changed in gnome-media (Ubuntu):
status: New → Incomplete
Revision history for this message
elmarco (marcandre-lureau) wrote :

Hmm, that is perhaps the reasons why I never saw that bug.

cat ~/.pulse/client.conf
autospawn = false

Can someone try if having this file configuration help?

thanks

Revision history for this message
Kai Huuhko (kai-huuhko) wrote :

> ~/.pulse/client.conf
> autospawn = false
>
> Can someone try if having this file configuration help?

With this the gnome-volume-control(-applet) doesn't try to reconnect, and so won't eat CPU cycles. Thanks!

And it can also be added to /etc/pulse/client.conf for system wide effect.

Revision history for this message
elmarco (marcandre-lureau) wrote :

Right, but we should probably add the PA_CONTEXT_NOAUTOSPAWN to g-v-c.

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

No we shouldn't. g-v-c-applet is a pulseaudio client and should be able to autospawn the daemon on demand, like it does currently. Rather than adding in workarounds for users who choose to go through the bother of uninstalling Pulseaudio, why don't you just remove the applet from System -> Preferences -> Startup Applications so the applet doesn't run at all?

Revision history for this message
Susan Cragin (susancragin) wrote :

Filed bug 588947 in bugzilla.gnome.org. They said basically it's a distribution problem. Perhaps someone would like to add more information to this bug.

http://bugzilla.gnome.org/show_bug.cgi?id=588947

Changed in gnome-media:
status: Unknown → Invalid
Revision history for this message
Chris Coulson (chrisccoulson) wrote :

Thanks Susan, I added a comment to the upstream report.

Rolf Leggewie (r0lf)
tags: added: karmic
Rolf Leggewie (r0lf)
Changed in gnome-media (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Vincenzo Ciancia (vincenzo-ml) wrote :

I risked to burn my laptop yesterday. It's extremely hot due to this bug. This must be given high priority. It CAN NOT be considered normal to have a process constantly eating cpu in the default desktop, especially on laptops, netbooks, and friends.

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

It's not high priority, as it does not use 40% CPU on a default install. It's only doing that for you because you broke it by uninstalling Pulseaudio. Admittedly, it shouldn't do that but it will not affect most users and doesn't affect a default install, so it's not high priority.

Revision history for this message
Rolf Leggewie (r0lf) wrote :

Vincenzo, this would not necessarily be a high prio bug even if it did affect a larger user base. Two suggestions for you:

1) "sudo renice 20 `pidof gnome-volume-control-applet`"
   Check the result with top. Your CPU should spent much time niced now.
2) change the CPU frequency governor with cpufreq-selector (or an applet).
   Forcing the CPU to a lower frequency should make sure it doesn't overheat

and ;-)

3) buy better hardware that doesn't overheat even under load in summer ;-)

Revision history for this message
Rolf Leggewie (r0lf) wrote :

above suggestions would work for all similar situations as well.

Vincenzo, you didn't read the bug carefully before ranting here unnecessarily. Comment 27 and 28 already tell you how to completely remedy the situation. Works fine for me, I don't see this problem anymore.

Revision history for this message
Vincenzo Ciancia (vincenzo-ml) wrote :

I did not understand that it was caused by pulseaudio missing, that's my fault, sorry. Then it is NOT a bug in the default desktop. Sorry for ranting, this is only a bug for those people that can't use pulseaudio (e.g. I need skype). Sorry for noise. In any case gnome-volume-control does NOT work anymore without pulseaudio so the best solution is the one I already had found: remove it.

Sorry again for noise. I was nervous because yesterday my laptop was seriously overheated.

Rolf: 2) is not a solution, I need cpu power for those who deserve it. 1) is a nice suggestion and I'd even have said "do it by default" but after last upgrade it does not make sense anymore 3) even nicer if you buy it for me *or* somebody starts actually selling arm-based things :)

Revision history for this message
Charlie Kravetz (cjkgeek) wrote :

I am raising this to high importance. I am running Xubuntu, which does not use pulse audio. I am seeing the same issues reported. Having the gnome-volume-control-applet using 40% of the cpu and attempting to spawn unknown other processes severely impacts the ability to work on the system. This bug was sent upstream upstream and they closed it as a distribution bug.

This does need to be resolved for Karmic to be useful.

Changed in gnome-media (Ubuntu):
importance: Low → High
Revision history for this message
Chris Coulson (chrisccoulson) wrote :

Charlie - you should rather report a bug to not start the applet in your XFCE session

Revision history for this message
Sebastien Bacher (seb128) wrote :

upstream consider it as a distribution issue to not have a hard depends on pulseaudio, would that fix the issue for xfce?

Revision history for this message
Vincenzo Ciancia (vincenzo-ml) wrote :

Charlie: I started this sub-discussion but with the latest upgrade I realised that gnome-volume-control does not work anymore with pulseaudio, so the only two fixes for this bug are: either use pulseaudio in xubuntu, or use a different mixer (e.g. fork the previous gnome mixer applet and maybe call it xfce-volume-control-applet).

Fixing this problem would not help your case: having a mixer applet sitting there, not using 40% cpu, but not controlling anything, is not useful.

Revision history for this message
Vincenzo Ciancia (vincenzo-ml) wrote :

I said "gnome-volume-control does not work anymore with pulseaudio". I obviously meant "gnome-volume-control does not work anymore _without_ pulseaudio".

Revision history for this message
Charlie Kravetz (cjkgeek) wrote :

I changed the importance back to low, this appears to have been fixed in Xubuntu with bug 400901.

Changed in gnome-media (Ubuntu):
importance: High → Low
importance: Low → Medium
importance: Medium → Low
Revision history for this message
Daniel Letzeisen (dtl131) wrote :

Chris Coulson: your patch in the upstream bug report looks nice and I hope it is accepted.

While one is able to work around the CPU usage issue with the autospawn = false hack, there is still this problem for those of us not using PulseAudio: https://bugs.launchpad.net/ubuntu/+source/gnome-media/+bug/400973

In Ubuntu 9.04/GNOME 2.26, I am still able to access my gstreamer sound preferences, event sounds, and control any chosen OSS4 volume with my keyboard's media keys, as long as gstreamer-plugins-bad is installed. PLEASE do not bork this in Ubuntu 9.10. If I need to open a new bug in GNOME's bugzilla to make them realize this is not just a "distribution problem" please let me know.

Revision history for this message
Vincenzo Ciancia (vincenzo-ml) wrote :

Ranting, not ranting, upstream commenting that pulseaudio should be made necessary for gnome volume control in distributions... and then... here is an interesting upstream comment!

 Comment #9 from Marc-Andre Lureau (gnome-media developer, points: 21)
2009-07-26 10:20 UTC [reply]

(In reply to comment #8)

> how can I use gnome-media without the pulseaudio? It used to work in previous
> versions but not in 2.27.x.

./configure --enable-gstmix

Now if some ubuntu developer could please investigate what this switch does and eventually enable that one for gnome-volume-control, that would be very very nice.

I mean: I am loving pulseaudio and even found some dirty workaround for skype (that is, disabling pulseaudio temporarily). But it would be even nicer if the gnome mixer could use its full power even without pulseaudio. That will not change anything in ubuntu and will improve its flexibility. I think upstream is going to maintain that code anyways so we should not worry.

Revision history for this message
elmarco (marcandre-lureau) wrote :

#45, Vincenzo,

The gstmix version of gnome-volume-control is deprecated. It is maintained for Solaris by Solaris guys. It's not meant to be a 1-1 substitute of the new gnome-volume-control, which uses the PulseAudio features (I won't make the long list here).

We decided to opt-in for PulseAudio 1 year ago, because it is the only way to move forward the audio stack on Linux. It is clearly the best we can do to improve sound experience with GNOME, and for that, GNOME need to depend on it.

The old gnome-volume-control based on gstmix is marked as deprecated. GStreamer folks are also in the process of deprecating the gstmixer interface in the next major release.

Eventually, some day, some folks will try to make an abstract audio mixer library. But this is not a simple task. And most probably, it won't depend on GStreamer this time.

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

This is resolved upstream now (the applet will be less agressive when trying to restart Pulseaudio)

Changed in gnome-media (Ubuntu):
status: Confirmed → Fix Committed
Revision history for this message
Chris Coulson (chrisccoulson) wrote :

elmarco - thanks for the explanation btw :)

Revision history for this message
Rolf Leggewie (r0lf) wrote :

Christ, shouldn't this be "fix committed" for upstream, but since nothing has been committed for ubuntu yet still just "confirmed"?

Revision history for this message
Rolf Leggewie (r0lf) wrote :

s/Christ/Chris/

sorry ;-)

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

Rolf - We generally use Fix Committed when fixed upstream for Gnome packages, because we know when they're going to roll new tarballs and they're generally on time - so if it is fixed upstream then it will be likely fixed in Ubuntu quite quickly.

Revision history for this message
Rolf Leggewie (r0lf) wrote :

OK, fair enough. So, we're quite certain this will be on time for Karmic?

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

Yes - It should be in the 2.27.5 tarball. The 2.27.5 tarballs are due to start landing tomorrow.

Revision history for this message
Vincenzo Ciancia (vincenzo-ml) wrote : Re: [Bug 400820] Re: gnome-volume-control-applet takes up to 40% cpu

Il 26/07/2009 17:46, Rolf Leggewie ha scritto:
> OK, fair enough. So, we're quite certain this will be on time for
> Karmic?

Guys what are you planning to do with gnome-volume-control without
pulseaudio? I don't get it: it's completely unuseful. If you remove
pulseaudio you will probably remove also gnome-volume-control.

Revision history for this message
Daniel Letzeisen (dtl131) wrote :

Vincenzo, see my comment above with the link to the other bug report. While it was great that this symptom was solved, it doesn't fix the root of the problem (too much hard-coded dependence on Pulse).

In GNOME 2.26, the applet is called gnome-sound-properties (this is what System->Preferences->Sound points to). You get a nice GUI to configure gstreamer, media keys, and event sounds regardless of whether or not you have Pulse (this was also working in Karmic/GNOME 2.27 until recently).

One can use the gstreamer-properties command and build gnome-media from source (using the --enable-gstmix flag) to get a rough equivalent to that GUI, but n00bs aren't going to grok this (especially the ones that removed Pulse to fix their audio issues). The sensible thing would be to use the fancy Pulse volume features if Pulse is detected and fall back on the proven gstmixer if not.

A little off-topic: The same "use Pulse if there, fallback to gstreamer if not" should also apply to libcanberra, which is another needlessly broken package for those not using ALSA/Pulse. (When I built it with the gstreamer backend, my system sounds worked fine, even with OSS4.) I filed a bug with Debian for that one, but I'm thinking of filing one here as well if it continues to get no response.

Revision history for this message
Sebastien Bacher (seb128) wrote :

GNOME is not going to be built suing the gst option, that would be duplicate feature or would require extra effort to add a new binary and users can as will install a mixer from universe if that's to add a new binary anyway

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

The fixed version is in Karmic now

Changed in gnome-media (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Tor Klingberg (tor-klingberg) wrote :

This kind of bug fix doesn't get backported to Jaunty, right?

Revision history for this message
smurf (luca-dgh) wrote :

for the peoples that removed Pulseaudio because skype.
the skype team has released a new beta of skype that is fully integrated with Pulseaudio. With the new beta of skype the controls of volume and device to use are totally in charge of Pulse and the cpu is not stressed when making a call.
So there are no more reasons to remove Pulseaudio.

Revision history for this message
Chris Balcum (sherl0k) wrote :

Uh, yes there is. Wine and Crossover still do not support Pulse. And for that reason I refuse to use it.

On top of that, ALSA alone has never, EVER given me a problem, whereas adding Pulse into the mix only causes them.

I find it completely preposterous that I can now not add the gnome-volume-control-applet to my panel, nor access the gnome-volume-control applet, without having Pulse installed. This is a complete joke. Forcing me to use a buggy sound system in order to just be able to control my volume control from the desktop? Seriously, you gotta be kidding me.

Revision history for this message
Daniel Letzeisen (dtl131) wrote :

Chris Balcum, this specific bug is fixed. If you want to get the developers' attention on the "please don't require Pulseaudio for basic audio functionality" issue, I suggest subsrcibing to: https://bugs.launchpad.net/bugs/400973

Revision history for this message
Susan Cragin (susancragin) wrote :

I have moved to that comment, too. People tend to think of wine as running stupid and optional games, but it's the only way for disabled people to get speech recognition on Linux, and I refuse to give it up.
And by the way, when alsa/wine runs speech rec, it runs it very well. The speed is great, the recognition is great, for text entry.

Another thing, pulseaudio will always be a handicap to those who use speech rec, because of latency issues and the layer of overlap, speech rec will never run with pulse as well as it does with alsa alone. Speech rec is a much more complex program than any single music app, or Skype. Those of us who need it willingly make sacrifices to use it.

Changed in gnome-media:
importance: Unknown → Critical
status: Invalid → Unknown
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.