Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.

Bug 497214

Summary: pulseaudio-module-x11 shouldn't autostart pulseaudio daemon if PULSE_SERVER is set
Product: [Fedora] Fedora Reporter: Warren Togami <wtogami>
Component: pulseaudioAssignee: Lennart Poettering <lpoetter>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: rawhideCC: lkundrak, lpoetter, wtogami
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-04-23 00:05:58 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On:    
Bug Blocks: 188611, 446451    

Description Warren Togami 2009-04-22 19:56:29 UTC
pulseaudio-0.9.15-10.fc11

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:
PULSE_SERVER=tcp:172.31.100.102:4713

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 20:17:14 UTC
Fixed upstream. Feel free to patch the Fedora packages.

Comment 2 Lennart Poettering 2009-04-23 00:05:58 UTC
Seems you patched the Fedora packages already, closing.

Comment 3 Fedora Update System 2009-05-05 16:41:09 UTC
pulseaudio-0.9.14-3.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/pulseaudio-0.9.14-3.fc10

Comment 4 Fedora Update System 2009-05-06 23:29:09 UTC
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.