Am 20.10.2016 um 15:16 schrieb Tanu Kaskinen: > On Sat, 2016-10-15 at 16:40 +0200, Florian Lindner wrote: >> Hello, >> >> this is a follow up to my previous thread. >> >> I'm using pulseaudio in system mode. It basically works fine, besides >> that the state is not restored. So I need to login and unmute the device >> after each boot. >> >> The device is an Asus Xonar PCIe card. >> >> Currently, for debugging I start pulseaudio manually after boot using >> the service file >> >> [Service] >> Type=notify >> ExecStart=/usr/bin/pulseaudio --daemonize=no --system --realtime >> --disallow-module-loading --disallow-exit --log-target=journal >> --log-level=debug >> >> I also changed the home directory of the pulse user from /var/run/pulse >> to /var/lib/pulse, to check if there are issues with an home that is >> cleared on each boot (what happens to /var/run/ afaik) >> >> The distribution is Arch, pulseaudio is on 9.0. >> >> Restore modules are loaded: >> >> # grep load-module /etc/pulse/system.pa >> load-module module-udev-detect >> load-module module-detect >> load-module module-esound-protocol-unix >> load-module module-native-protocol-unix >> load-module module-default-device-restore >> load-module module-stream-restore >> load-module module-device-restore >> load-module module-card-restore >> load-module module-native-protocol-tcp auth-anonymous=true >> load-module module-zeroconf-publish >> load-module module-rescue-streams >> load-module module-always-sink >> load-module module-suspend-on-idle >> load-module module-position-event-sounds >> >> The log output is attached or at http://pastebin.com/AxJBCqAz > > The log doesn't show any changes in the sink mute state. The log shows > some mute toggling of tunnel streams, however: > > Okt 15 16:25:52 marduk pulseaudio[855]: The mute of sink input 2 changed from no to yes. > Okt 15 16:25:52 marduk pulseaudio[855]: The mute of sink input 2 changed from yes to no. > Okt 15 16:25:53 marduk pulseaudio[855]: The mute of sink input 1 changed from no to yes. > Okt 15 16:25:53 marduk pulseaudio[855]: The mute of sink input 1 changed from yes to no. > Okt 15 16:25:55 marduk pulseaudio[855]: The mute of sink input 3 changed from no to yes. > Okt 15 16:25:55 marduk pulseaudio[855]: The mute of sink input 3 changed from yes to no. > > It seems that sink input 1 is a tunnel stream for the internal sound > card, and sink inputs 2 and 3 are both tunnel streams for the Xonar > card. Do you have two tunnel sinks loaded for the Xonar card? As I noted above, I have module native-protocol-tcp without auth loaded. However, during this log (which is only startup of pulseaudio) I did not connect from the outside (at least not played a stream, maybe the other machine connected anyway to the server, since the remote source was available) > The mute events don't really match your description of the problem, > though, because the initial mute state seems to be unmuted, and these > events just quickly toggle unmuted -> muted -> unmuted, so there's only > a very short time (less than a second according to the time stamps) > when the stream is muted. > > What if you don't connect from outside at all? If you ssh into the > server after booting, do you get audio if you run I always test with a local sound source, no network stream. > paplay --device=alsa_output.pci-0000_03_04.0.analog-stereo /usr/share/sounds/alsa/Front_Center.wav Right after boot, login via SSH: paplay --device=alsa_output.pci-0000_03_04.0.analog-stereo /usr/share/kodi/addons/resource.uisounds.confluence/resources/notify.wav -> no sound pactl set-sink-mute alsa_output.pci-0000_03_04.0.analog-stereo 0 pactl set-sink-volume alsa_output.pci-0000_03_04.0.analog-stereo 100% paplay --device=alsa_output.pci-0000_03_04.0.analog-stereo /usr/share/kodi/addons/resource.uisounds.confluence/resources/notify.wav -> sound (side note: the volume state is also not restored) >> After I unmute the device, a restart pulseaudio.service does not mute it >> again. It only happens at a system reboot. >> >> Is there a way to use pacmd or alike to connect to the system daemon and >> unmute the device? Currently I login and use pavucontrol. > > "pactl set-sink-mute", see "man pactl" for details. Is it ok, pactl fails, when executed as root? # pactl set-sink-mute alsa_output.pci-0000_03_04.0.analog-stereo 0 Connection failure: Access denied I hope it was a little bit helpful to pin down the problem, I'm very happy to provide any more information. It helped me much you mentioned pacctl, at least now I don't need to login graphically to set the mute status. Thanks a lot for your help! Florian