[pulseaudio-discuss] Using "expect" to feed pacmd

Whit Blauvelt whit.pulse at transpect.com
Fri Sep 10 07:14:10 PDT 2010


On Fri, Sep 10, 2010 at 01:44:31PM +0100, Colin Guthrie wrote:

> The /etc/inid.d script should ONLY be used for system wide PA. We do not
> even provide such a script in our upstream tarballs and generally
> discourage using PA in system wide mode. 

That's good design from a traditional *nix perspective, assuming any system
may have multiple users. I think where it collides with a distro like Ubuntu
is that Ubuntu has two main use cases: servers where it may have many users
but won't have a GUI and is unlikely to be involved with sound, and then
desktops on notebooks where there's a polished GUI and generally only a
single user. Canonical must figure that for single user systems system-wide
mode isn't so bad.

But then in the Ubuntu forums there are many, many reports of people going
System > Preferences > Sound and then getting nothing but a message about
waiting for the sound system to start. Obviously it works for many much of
the time. But it also breaks for many too. It could be this fragility is
just in running it system-wide. Maybe Canonical just shouldn't do that.
Nonetheless, for now, your largest user base is probably on Ubuntu, and if
it's not going to work so well in system-wide mode, either Canonical or
Pulseaudio should work things out so it does, or else doesn't even try to
work that way.

> In the default, per-user setup that we ship, PA auto-spawns, so exiting
> the daemon is generally not overly problematic (clients which support
> reconnect will do so automatically).

I'm all for building stuff from source, but sound is such a complex stack
I'd worry about how much other stuff would need to be from source rather
than from the distro's packages in order to keep this stable as other system
components go through their upgrade cycles. Meanwhile is there a right way
to restart the daemon on any level at all under Ubuntu without having to
reboot? If the init.d script doesn't do it, and "pulseaudio&" at the command
prompt doesn't do it, what's the invocation that would? Or does Ubuntu's
having started it system-wide the first time around mean there's just no way
to get there?

> I take your point re the "exit" command tho'. I am tempted to agree with
> you. I just never, ever type exit on any terminal out of habit (ctrl+D
> is much quicker) and thus I've never really noticed this.

Hmm. Stretch for control, hold it down, then press D - or just type "exit"
from home position - same speed for me, and what with different keyboards
moving ctrl around, often faster to type "exit." I only use ctrl-D in Python
; >

Best,
Whit



More information about the pulseaudio-discuss mailing list