[pulseaudio-discuss] pulseaudio startup

Tanu Kaskinen tanuk at iki.fi
Sat Mar 12 14:39:55 UTC 2016


On Sat, 2016-03-12 at 06:36 -0500, Jude DaShiell wrote:
> I put code in my .bashrc file to start pulseaudio up and that does not 
> work for some reason.  I have rc.local I can use to get this started 
> before login and would prefer to have it started that early if possible. 
> I am using a command line interface on a screen reader so pulseaudio could 
> in theory help manage which speakers screen reader output went during and 
> after login.

You use an Arch-based distribution, right? Arch runs pulseaudio as a
systemd user service, and uses socket activation. This means that
systemd starts pulseaudio as soon as some application tries to connect
to the pulseaudio socket. It's unnecessary to start pulseaudio from
.bashrc, and if you try to do that, it will fail, because pulseaudio
will try to bind to the same socket that systemd has reserved.

Setting up things so that the screen reader works before login is
something that the distribution should do for you, but if you really
want to try to make it work, here are some hints (I don't have exact
instructions):

Run pulseaudio in the system mode rather than in the normal per-user
mode. This means that root starts pulseaudio with the --system
parameter, and pulseaudio will then switch its user to "pulse".

Make sure that the user "pulse" has access to the devices under
/dev/snd.

Add your regular user and the user under which the screen reader runs
to the "pulse-access" group.

Disable the pulseaudio systemd user service so that it doesn't try to
run pulseaudio when the system-wide daemon is running.

Note that the system mode uses /etc/pulse/system.pa instead of
/etc/pulse/default.pa for configuration.

-- 
Tanu


More information about the pulseaudio-discuss mailing list