On Wed, 01 Apr 2020 19:22:41 +0200, Andrei Borzenkov wrote:
01.04.2020 19:27, Manfred Hollstein пишет:
Hi there,
this is on build ID 617.1. I use the script setup-pulseaudio sometimes to disable pulseaudio for a user session. This used to work without any trouble (on Leap 15.1 at least), but today I still found two processes running when logged in: "/usr/bin/pulseaudio --daemonize" and "/usr/lib/pulse/gconf-helper". And indeed, running "pavucontrol" doesn't hang/stop as it normally does when PA is disabled.
pavucontrol socket activates PA ...
%post /sbin/ldconfig %tmpfiles_create pulseaudio.conf %{fillup_only -an sound} if [ ! -f /etc/systemd/user/sockets.target.wants/%{name}.socket ]; then echo "Switching PulseAudio activation using systemd user socket." echo "Please log out from all sessions once to make it effective." fi %systemd_user_post pulseaudio.socket if [ ! -f /etc/systemd/user/sockets.target.wants/%{name}.socket ]; then # below should work once when preset is defined properly: # /usr/bin/systemctl --no-reload --global preset pulseaudio.socket mkdir -p /etc/systemd/user/sockets.target.wants ln -s %{_userunitdir}/%{name}.socket /etc/systemd/user/sockets.target.wants/%{name}.socket fi
And if preset will ever support global user activation, it will be impossible to disable it. systemd does not offer any possibility to disable units enabled globally (in /usr/lib/systemd).
Yeah, actually it's a fallout at transition to the user socket from the old autospawn invocation. It's a bit ugly but changing /usr/lib/systemd/user/pulseaudio.service like below should honor /etc/sysconfig/sound setup. OTOH, you should be able to disable the systemd user setup easily, too, so I'm hesitated for taking that... Takashi