|# systemd service spec for pulseaudio running in system mode -- not recommended though!|
|# on arch, put it under /etc/systemd/system/pulseaudio.service|
|# start with: systemctl start pulseaudio.service|
|# enable on boot: systemctl enable pulseaudio.service|
|Description=Pulseaudio sound server|
|ExecStart=/usr/bin/pulseaudio --system --disallow-exit --disallow-module-loading|
|ExecReload=/bin/kill -HUP $MAINPID|
Pulseadio configured correctly forks and drops root privileges, and runs under the user pulse.
I can't get it working on my intel-nuc running CentOs 8.
Root cause (?):
FYI this is what is written by pulseaudio in the log file when started by
This is what is logged by pulseaudio when starting from command line as user root:
Setup of pulseaudio in user mode
loginctl enable-linger pulseaudio # you can check this by below command which should return a line like: # pulseau+ 1187308 1 0 10:32 ? 00:00:00 /usr/lib/systemd/systemd --user ps -ef | grep pulse | grep systemd
This can be checked by:
Test pulseaudio installation (including pavucontrol)
dnf install pavucontrol # assure that XQuartz is running on macbook and # that you have enabled remote access (type "xhost +" in xterm window) # you can then launch pavocontrol by following command export PULSE_SERVER=unix:/run/user/1041/pulse/native; pavucontrol --display=Jans-MBP.lan:0.0
Accessing pulseaudio server (on host) in docker container
Assure that pulseaudio server (on host) is setup as in previous sections.
Change pulseaudio profile (using hdmi / analog / digital output)
Here below the commands to change the audio profile of the card.