Bug 497214 - pulseaudio-module-x11 shouldn't autostart pulseaudio daemon if PULSE_SERVER is set
pulseaudio-module-x11 shouldn't autostart pulseaudio daemon if PULSE_SERVER i...
Product: Fedora
Classification: Fedora
Component: pulseaudio (Show other bugs)
All Linux
low Severity medium
: ---
: ---
Assigned To: Lennart Poettering
Fedora Extras Quality Assurance
Depends On:
Blocks: K12LTSP F11Target
  Show dependency treegraph
Reported: 2009-04-22 15:56 EDT by Warren Togami
Modified: 2009-05-06 19:29 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2009-04-22 20:05:58 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Warren Togami 2009-04-22 15:56:29 EDT

pulseaudio-module-x11 contains /etc/xdg/autostart/pulseaudio.desktop which autostarts /usr/bin/start-pulseaudio-x11 during a desktop login.

Remote desktop sessions might set PULSE_SERVER to direct the desktop sound to another host, like:

In this case, the pulseaudio daemon launched by the user desktop is not actually used.  This can actually cause problems for multi-user systems because these unused pulseaudio and /usr/libexec/pulse/gconf-helper processes often fail to die after logout.  Hundreds of them pile up over time bogging down system resources.

--- /usr/bin/start-pulseaudio-x11.orig	2009-04-22 15:42:00.281756540 -0400
+++ /usr/bin/start-pulseaudio-x11	2009-04-22 15:45:04.465837091 -0400
@@ -19,6 +19,9 @@
 set -e
+# Exit without running pulseaudio daemon if this is a remote desktop session
+[ -n "$PULSE_SERVER" ] && exit 0
 /usr/bin/pulseaudio --start "$@"
 if [ x"$DISPLAY" != x ] ; then

This patch seems to DTRT, preventing the unused pulseaudio daemon from launching, and no more leftover processes after user logout.
Comment 1 Lennart Poettering 2009-04-22 16:17:14 EDT
Fixed upstream. Feel free to patch the Fedora packages.
Comment 2 Lennart Poettering 2009-04-22 20:05:58 EDT
Seems you patched the Fedora packages already, closing.
Comment 3 Fedora Update System 2009-05-05 12:41:09 EDT
pulseaudio-0.9.14-3.fc10 has been submitted as an update for Fedora 10.
Comment 4 Fedora Update System 2009-05-06 19:29:09 EDT
pulseaudio-0.9.14-3.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.