<div dir="ltr"><span id="docs-internal-guid-75bd7ecf-86da-6996-68f3-c438afbcef73"><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;color:rgb(0,0,0);vertical-align:baseline;white-space:pre-wrap;background-color:transparent">Hi I have been trying unsuccessfully to use pulseaudio with lxc.</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;color:rgb(0,0,0);vertical-align:baseline;white-space:pre-wrap;background-color:transparent">host: Ubuntu 15.04, with nvidia cuda (runs X11 gnome 3.14) on vt7</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;color:rgb(0,0,0);vertical-align:baseline;white-space:pre-wrap;background-color:transparent">lxc guest: Archlinux with nvidia cuda driver (runs X11 gnome 3.16) on vt8</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;color:rgb(0,0,0);vertical-align:baseline;white-space:pre-wrap;background-color:transparent">pulseaudio is running in the host (192.168.x.x)</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;color:rgb(0,0,0);vertical-align:baseline;white-space:pre-wrap;background-color:transparent">the lxc guest connects to the host as follows (done in .xinitrc):</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;color:rgb(0,0,0);font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:transparent">pactl load-module module-native-protocol-tcp auth-ip-acl="192.168.0.3"</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;color:rgb(0,0,0);font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:transparent">export PULSE_SERVER=192.168.x.x:4713</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;color:rgb(0,0,0);vertical-align:baseline;white-space:pre-wrap;background-color:transparent">in the server I have  the following in /etc/pulse/<a href="http://default.pa">default.pa</a></span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;color:rgb(0,0,0);font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:transparent">load-module module-native-protocol-tcp</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;color:rgb(0,0,0);font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:transparent">load-module module-native-protocol-tcp auth-ip-acl=127.0.0.1;<a href="http://192.168.0.0/24">192.168.0.0/24</a> auth-anonymous=1</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">aplay -l | grep card: (in the guest and host):</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">card 0: PCH [HDA Intel PCH], device 0: 92HD89E2 Analog [92HD89E2 Analog]</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">card 0: PCH [HDA Intel PCH], device 1: 92HD89E2 Digital [92HD89E2 Digital]</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">card 1: NVidia [HDA NVidia], device 3: HDMI 0 [HDMI 0]</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">card 1: NVidia [HDA NVidia], device 7: HDMI 1 [HDMI 1]</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">card 1: NVidia [HDA NVidia], device 8: HDMI 2 [HDMI 2]</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">card 1: NVidia [HDA NVidia], device 9: HDMI 3 [HDMI 3]</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">When I play in the lxc guest I get the following</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">mplayer /usr/share/sounds/alsa/Front_Right.wav:</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">MPlayer SVN-r37379 (C) 2000-2015 MPlayer Team</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">210 audio & 441 video codecs</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">do_connect: could not connect to socket</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">connect: No such file or directory</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Failed to open LIRC support. You will not be able to use your remote control.</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Playing /usr/share/sounds/alsa/Front_Right.wav.</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">libavformat version 56.25.101 (internal)</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Audio only file format detected.</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Load subtitles in /usr/share/sounds/alsa/</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">==========================================================================</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Opening audio decoder: [pcm] Uncompressed PCM audio decoder</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">AUDIO: 48000 Hz, 1 ch, s16le, 768.0 kbit/100.00% (ratio: 96000->96000)</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Selected audio codec: [pcm] afm: pcm (Uncompressed PCM)</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">==========================================================================</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">AO: [pulse] 48000Hz 1ch s16le (2 bytes per sample)</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Video: no video</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Starting playback...</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">A:   0.0 (unknown) of 1.0 (01.0) ??,?% </span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Audio device got stuck!</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">A:   0.0 (unknown) of 1.0 (01.0) ??,?% </span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Audio device got stuck!</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">A:   0.0 (unknown) of 1.0 (01.0) ??,?% </span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Audio device got stuck!</span></p><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">A:   0.0 (unknown) of 1.0 (01.0) ??,?% </span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;font-style:italic;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">…</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Clearly there is some communication/permission issue that I do not fully understand.</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Any help will be appreciated.</span></p><br><p dir="ltr" style="line-height:1.38;margin-top:0pt;margin-bottom:0pt"><span style="font-size:15px;font-family:Arial;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)">Thanks</span></p><div><span style="font-size:15px;font-family:Arial;vertical-align:baseline;white-space:pre-wrap;background-color:rgb(235,241,245)"><br></span></div></span></div>