Remote iTunes Streaming
Are you ever away from home and wish you had your music library available? I certainly do, so I’ve done something about it.
First, a bit about my environment:
- Server:
- Windows Home Server
- Debian “Lenny” running in a VM
- Behind a Linksys WRT54G running Tomato
- SSH forwarded into the linux VM
- Client
- Windows Vista Enterprise
- Behind an ISA firewall
To accomplish this task, I used the following tools:
- smbfs - Samba filesystem kernel module
- mt-daapd - Firefly media server
- Putty - Windows SSH client
- Rendezvous Proxy - Windows utility that proxies the Apple Rendezvous protocol from an arbitrary network address
Here is what I did, step by step:
1) Setup Debian to automatically mount my Home Server’s music share on boot:
$ sudo mkdir /mnt/mp3 $ sudo vim /etc/fstab
Add a line to the end of the file like this:
//<ipaddress>/Music /mnt/mp3 smbfs username=<username>,password=<password> 0 0
Where <ipaddress> is the IP of your media server, and <username> and <password> are a login that has access to the file share
Then, I mounted the share manually to avoid having to restart:
$ sudo mount /mnt/mp3
2) Setup mt-daapd (you can grab this from sourceforge at http://tinyurl.com/mt-daapd):
$ wget <url path to mt-daapd tarball> $ tar -zxvf <path to tarball> $ cd mt-daapd-x.x.x.x # x's are in place of the version number $ ./configure $ make $ sudo make install
Now you need to configure mt-daapd:
$ sudo cp contrib/mt-daapd.conf /etc $ sudo cp contrib/mt-daapd.playlist /etc $ sudo vim /etc/mt-daapd.conf
Most of the defaults should be fine, but you’ll need to change web_root from /usr/share/… to /usr/local/share/… You’ll also want to change the admin_pw to a more secure password.
Next, we’ll make mt-daapd load on boot automatically:
$ cd /etc/init.d $ sudo ln -s /usr/local/sbin/mt-daapd mt-daapd $ sudo update-rc.d mt-daapd defaults
We’re now ready to launch mt-daapd:
$ sudo /etc/init.d/mt-daapd start
Ok, barring any errors, you’ve now got sharing working locally. The next step is to get to that share remotely.
3) Setup an SSH tunnel to your media server.
On your client machine, launch Putty and input the following settings:
- Session
- Host Name (or IP address): the hostname or IP of your router. In my case, I have a dynamic IP, so I use dyndns.org along with the appropriate settings in my router’s firmware.
- Connection type: SSH
- SSH
- Check “Don’t start a shell or command at all”
- Check “Enable compression”
- SSH -> Tunnels
- Source port: 3689
- Destination: your linux box’s local IP plus port 3689 (ex. 192.168.1.100:3689)
- Click Add
You’ll probably also want to save this configuration in the Session tab. Optionally, you can setup SSH Key authentication so you don’t have to type your password every time you connect.
4) Setup Rendezvous Proxy:
Install Rendezvous proxy (download link above) and run the application
Click Add Host and input the following settings:
- IP Address: localhost (we direct the traffic to our SSH tunnel this way)
- Port: 3689
- Host Label: what shows up in iTunes
- Service Type: _daap._tcp. (iTunes Host)
Click Add and then launch iTunes. You should now see your home media server in the left column. Have fun!
(Thanks to Luc Dewavrin for his tutorial on setting this up. It took some extra steps, but his documentation was priceless)
About this entry
You’re currently reading “ Remote iTunes Streaming ,” an entry on decompiled
- Published:
- 7.28.08 / 2pm
« Previous Post | Next Post »

1 Comment
Jump to comment form | comments rss [?] | trackback uri [?]