{"id":41,"date":"2006-07-12T13:22:06","date_gmt":"2006-07-12T11:22:06","guid":{"rendered":"http:\/\/www.hackenberger.at\/wordpress\/?page_id=41"},"modified":"2006-07-12T13:41:01","modified_gmt":"2006-07-12T11:41:01","slug":"how-to-play-sound-on-a-remote-server","status":"publish","type":"page","link":"https:\/\/www.hackenberger.at\/blog\/linux-guides\/gentoo-guides\/how-to-play-sound-on-a-remote-server\/","title":{"rendered":"Playing sound on a remote system"},"content":{"rendered":"<p><strong>Instructions how to play sound on a remote server<\/strong><br \/>\nUsing the KDE sound daemon &#8220;artsd&#8221; it is possible to play all sounds on a remote machine running artsd. You could e.g. use you laptop to control JuK, but play this music on a machine which is connected to your HiFi system digitally.<\/p>\n<p>You have to install the artsd on both machines. Now you have to tell the artsd daemons to use the X11 root window properties for communication establishment. To accomplish this task you have to edit the ~\/.mcoprc file of the user who starts the artsd (usually this would be your normal user on the laptop and root on the machine acting as the server). Replace the following line:<br \/>\nGlobalComm=Arts::TmpGlobalComm<br \/>\nwith this:<br \/>\nGlobalComm=Arts::X11GlobalComm<\/p>\n<p>On the server you probably need a startup script to start the artsd, since you probably have no KDE running there. You can use script below.<\/p>\n<blockquote><p>#!\/sbin\/runscript<\/p>\n<p>depend() {<br \/>\nneed alsasound<br \/>\n}<\/p>\n<p>start() {<br \/>\nebegin &#8220;Starting Artsd&#8221;<br \/>\nstart-stop-daemon &#8211;background &#8211;start &#8211;quiet &#8211;exec \/usr\/kde\/3.3\/bin\/artsd &#8212; -n -u -p 5$<br \/>\neend $?<br \/>\n}<\/p>\n<p>stop() {<br \/>\nebegin &#8220;Stopping Artsd&#8221;<br \/>\nstart-stop-daemon &#8211;stop &#8211;quiet &#8211;exec \/usr\/kde\/3.3\/bin\/artsd<br \/>\neend $?<br \/>\n}<\/p><\/blockquote>\n<p>Please note that the -u option disables authentification. This may be a security issue for you. I have not yet tried to work around this.<\/p>\n<p>On the client (in my case the laptop) you have to tell the applications to send the sound ouput to the server. Therefore you have to set the ARTS_SERVER evironment variable.<\/p>\n<blockquote><p>export ARTS_SERVER=192.168.123.158:5001<\/p><\/blockquote>\n<p>Of course you have to change the ip address accordingly. \t\t\t\tMaybe setting ALSA_SERVER to the same also works.<br \/>\nYou can add:<\/p>\n<blockquote><p>ARTS_SERVER=hacki-server:5001<\/p><\/blockquote>\n<p>to \/etc\/env.d\/00basic so that the variable is set globally \t\t\t\tduring start-up.<br \/>\nAfter restarting artsd on the server everything should work \t\t\t\tas desired.<br \/>\nPlease note, that the artsd on the client must not be running!<br \/>\nPS: You can do the same with esd (the Gnome sound daemon). \t\t\t\tJust start esd on the host with the soundcard:<\/p>\n<blockquote><p>esd -tcp -public -port 5001<\/p><\/blockquote>\n<p>and then add the line:<\/p>\n<blockquote><p>export ESPEAKER=sound-server:5001<\/p><\/blockquote>\n<p>(where sound-server is the hostname, or IP of your server with \t\t\t\tthe soundcard.) to \/etc\/env.d\/00basic<br \/>\nHave fun!<\/p>\n<blockquote><p><code \/><\/p>\n<pre \/><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>Instructions how to play sound on a remote server Using the KDE sound daemon &#8220;artsd&#8221; it is possible to play all sounds on a remote machine running artsd. You could e.g. use you laptop to control JuK, but play this music on a machine which is connected to your HiFi system digitally. You have to &hellip; <a href=\"https:\/\/www.hackenberger.at\/blog\/linux-guides\/gentoo-guides\/how-to-play-sound-on-a-remote-server\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Playing sound on a remote system<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":35,"menu_order":0,"comment_status":"open","ping_status":"open","template":"","meta":[],"_links":{"self":[{"href":"https:\/\/www.hackenberger.at\/blog\/wp-json\/wp\/v2\/pages\/41"}],"collection":[{"href":"https:\/\/www.hackenberger.at\/blog\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.hackenberger.at\/blog\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.hackenberger.at\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hackenberger.at\/blog\/wp-json\/wp\/v2\/comments?post=41"}],"version-history":[{"count":0,"href":"https:\/\/www.hackenberger.at\/blog\/wp-json\/wp\/v2\/pages\/41\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/www.hackenberger.at\/blog\/wp-json\/wp\/v2\/pages\/35"}],"wp:attachment":[{"href":"https:\/\/www.hackenberger.at\/blog\/wp-json\/wp\/v2\/media?parent=41"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}