This is an old revision of the document!


iTunes Server

The DNS-323 is delivered with an iTunes Server included. This server is the open source mt-daapd server, version 0.2.4.This is the reccomended stable release of mt-daapd which also supports iTunes 6.0.4.

After 0.2.4, mt-daapd evolved into FireFly, self-titled to be The best open-source media server for the Roku SoundBridge and iTunes. FireFly is work-in-progress, but Roku has decided that one of the nighly builds are good enough for their customers and released version 1.0.

In short, there is no FireFly version 1.0 from the developer, Ron Pedde but Roku, the corporation, has decided to define one. See this thread for information about this issue.

FireFly on the DNS-323

There are, at least, two ways to get FireFly running on the DNS-323. Either through the debian chroot or as a standalone application.

FireFly in Debian Chroot

To get started, chroot into a debian Sarge system on the DNS-323 following this howto.

Next step is to install the files that FireFly depends upon.

apt-get install libsqlite0
apt-get install libsqlite0-dev
apt-get install libid3tag0-dev

Then, download and extract one of the nightly releases, e.g. the SVN-1498.

Next step is to compile it:

./configure
make
make install

Create a mt-daapd.conf, use example from ./contrib directory and place it in /usr/local/etc/.

Additionaly, you need a few directories not present in the debian sarge distrobution:

mkdir /usr/local/etc
mkdir /usr/local/var
mkdir /usr/local/var/cache
mkdir /usr/local/var/cache/mt-daapd

Now you're ready to start your FireFly server. Issue the command mt-daapd and you're all set. Though, I recommend you to start it with '-f' the first time.

FireFly in Standalone Mode

First, set up your crosscompile toolchain and download build_firefly_pa1.tgz.

FIXME The file contains a bug and needs to be edited. On line 196, remove the exit command.

This file contains a script which downloads, patches, compiles and installs all files required by FireFly. It also includes a number of patch files required for this package to crosscompile.

Extract the file in the GPL directory created while crosscompiling and execute the script ./build_firefly.

This should result in a file called dns323_mt-daapd-svn-1498.tar.gz which you transfer to /mnt/HD_a2 and extract using lnx_bin/busybox3 tar xvz -f dns323_mt-daapd-svn-1498.tar.gz.

The files installed are updated versions of files already present on the DNS-323. In order to use this package you need to point out the directory for the shared libraries used.

In order to start FireFly execute the following, but first make sure that the <hi #ffa500>iTunesServer is turned off</hi>.

export LD_LIBRARY_PATH=/mnt/HD_a2/lnx_bin/lib
/mnt/HD_a2/lnx_bin/mt-daapd -f -c /mnt/HD_a2/lnx_bin/mt-daapd.conf

Note that the argument -f starts the FireFlyserver in foreground. This in combination with debug mode -d 9 is a great tool when starting FireFly for the first time as it shows you potential errors. Omit these flags to start a deamon instead.

When FireFly is up and running, access it from your browser on port 3689, e.g. http://192.168.0.200:3689. The adminstors password is default set to mt-daapd. This is easlily changed by modifying the mtdaapd.conf file.

Standalone - The Easy Way

Method 1 Use WinRAR and FTP Access:

  1. Turn off original iTunesServer from D-Link from WEB GUI, <hi #ffff00>IMPORTANT</hi>
  2. For the version with FLAC support compiled in, download dns323_mt-daapd-svn-1498-with-flac.tar.gz
  3. Use WinRAR to decompress all the files in the archive (Do not, I repeat, do not try to use Winzip to extract the contents of the tar file. If you do that, you will not be able to start FireFly.)
  4. Use an editor such as Notepad++ edit the entry on line 78 to point to your music files (i.e. if your music files are in a folder called Music, then change the entry to 'mp3_dir = /mnt/HD_a2/Music').
  5. Use FTP access to place the files in \\NAS\HDD_1 or \\NAS\Volume_1 (depends on FW version)
  6. Telnet into device and execute (note that each line is a separate command)
cd /mnt/HD_a2
export PATH=/mnt/HD_a2/lnx_bin:$PATH
export LD_LIBRARY_PATH=/mnt/HD_a2/lnx_bin/lib
/mnt/HD_a2/lnx_bin/mt-daapd -f -c /mnt/HD_a2/lnx_bin/mt-daapd.conf

Method 2 Use TAR and Telnet on the DNS-323:

  1. Turn off original iTunesServer from D-Link from WEB GUI, <hi #ffff00>IMPORTANT</hi>
  2. For the version with FLAC support compiled in, download dns323_mt-daapd-svn-1498-with-flac.tar.gz
  3. Place the file in \\NAS\HDD_1 or \\NAS\Volume_1 (depends on FW version)
  4. Telnet to device and execute:
cd /mnt/HD_a2
lnx_bin/busybox3 tar xvz -f dns_323_firefly_svn_mt-daapd-svn-1498_pa2.tar.gz
export PATH=/mnt/HD_a2/lnx_bin:$PATH
export LD_LIBRARY_PATH=/mnt/HD_a2/lnx_bin/lib
/mnt/HD_a2/lnx_bin/mt-daapd -f -c /mnt/HD_a2/lnx_bin/mt-daapd.conf

You will see the output from the program as it runs, and need to press CTRL+C to stop it when you are done testing. When you've started the server, access it on port 3689 using your regular browser: http://192.168.0.200:3689. The admin password is defualt set to be mt-daapd.

Standalone - fun_plug

The FireFly server can also be started using the fun_plug. Provided that you have already tested your setup, this fun_plug will do the trick:

#!/bin/sh
if [ -f /mnt/HD_a2/lnx_bin/mt-daapd ]
then
  export PATH=/mnt/HD_a2/lnx_bin:$PATH
  export LD_LIBRARY_PATH=/mnt/HD_a2/lnx_bin/lib
  /mnt/HD_a2/lnx_bin/mt-daapd -c /mnt/HD_a2/lnx_bin/mt-daapd.conf
fi

A file that contains this code can be download here: firefly_funplug_startup_script-0.1.tar.gz. See the fun_plug documentation on how to install a funplug script.


Navigation

Personal Tools