[pulseaudio-discuss] system-wide daemon

Bill Cox waywardgeek at gmail.com
Sun Feb 7 19:54:51 PST 2010

While the "right" way is not system-wide mode, in practice, I find
system-wide mode to be very stable and usable on Ubuntu systems that
have multiple users trying to send sound to the speakers.  It's easy
to get Ubuntu Karmic and Lucid to use PulseAudio in system-wide mode.
For systems that require rock-solid sound, and which need to share the
sound card simultaneously with multiple users, it's what I currently
recomend.  Long-term, I believe this situation will change, but for
now, in Ubuntu, system-wide mode would be my recomendation for you.
To set system-wide mode:

Edit /etc/defaults/pulseaudio, and change:

Then, edit /etc/pulse/client.conf, and add the line
    autospawn = no
After the line that says '#autospawn = yes'.  Then, delete the file

Finally, disable group-based authentication to use the sound system.
Edit /etc/pulse/system.pa.  Find the line that reads:
    load-module module-native-protocol-unix
and change it to read:
  load-module module-native-protocol-unix auth-anonymous=1

Be warned that you open yourself up to a unauthorized sound hacker
attacks!  Your wife could send perverse audio over your speakers
without permission!  Your children could spy on you through your mic
without your password!

If you're a bit confused, join the club.  In any case, I my system
works very well in system-wide mode, and for my purposes it works far
better than user-mode, but I've got multiple programs running as
different users that need simultaneous access to the sound card.


On Sun, Feb 7, 2010 at 6:54 PM,  <olin.pulse.7ia at shivers.mail0.org> wrote:
> I am trying to understand PulseAudio, and have some use cases for which
> it's not clear to me how best to configure the system.
> In my living room at home, I have a pair of stereo speakers, which are
> connected to a linux box, which, in turn, has some large disks holding a
> large music collection. When you wish to play music in my home, you do
> it by running a program of some sort on this computer.
> Now, the thing is that this computer has a monitor, keyboard and mouse.
> Sometimes someone is logged in to this console, doing things on the
> computer. Sometime no one is logged in at all.
> Now, as I am typing this very message, I am sitting on my couch in my
> living room, using my notebook computer. What I would also like to do,
> for example, is ssh into my living room server, run rythmbox, and play
> some music. Perhaps my wife is logged in to the console; perhaps she
> isn't. Perhaps I am. That's irrelevant. My music server is a multi-user
> system; multiple people can be simultaneously logged in to the system,
> and all of them should be able to access the audio hardware.
> It seems to me that this is the sort of thing for which one wants a
> system-wide pulse daemon. Pulse Audio seems to be tuned towards the
> idea of having a daemon launched per login session. But I would like
> multiple users in my home to be able to remotely connect to my music
> system and run programs that send audio to the speakers. This should
> be completely independent of who is logged in at the console.
> On the other hand, I've read the PulseAudio wiki seeking enlightenment,
> and the wiki very clearly disrecommends using PA in system-daemon mode.
> It doesn't make a very compelling case of *why* system-daemon mode is
> a bad idea, it mostly just explains that PA will restrict functionality
> for security reasons if you obstinately insist on doing so.
> So, what's the right way to handle the use case I've outlined?
>    -Olin
> _______________________________________________
> pulseaudio-discuss mailing list
> pulseaudio-discuss at mail.0pointer.de
> https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss

More information about the pulseaudio-discuss mailing list