NAS Guides

From JonWiki

jontse.com > HOWTOs > NAS Guides
Jump to: navigation, search

Overview

NAS, for those who don't know, stands for Network Attached Storage, and it is what it sounds like.

So, for awhile, I've been using Windows Media Player 11 as my DLNA server for streaming media to my PS3 and my Xbox 360. The downside to using WMP 11 is that you need a full-fledged computer to run it.

WMP 11

One of the benefits of WMP 11, though, is that it's really easy to set up. All you need is to install WMP 11, import your media into the library, turn on sharing for the client device, and you're all set. You have the benefit of running Windows, so you can do all sorts of other server-y stuff that's useful.

WMP 11 even handles the transcoding for you, so it's even cooler.

D-Link DNS-323

I decided to "downgrade" from a full-fledged Windows box to a D-Link DNS-323 NAS device. It's a nice little box, holds 2 SATA drives, and has a network port. It runs some barebones version of Linux, which I think is BusyBox. It has a built-in iTunes server, a uPnP media server (which doesn't work with PS3's, apparently), an FTP server, and a simple web server. All in all it's very flexible right from the get-go, but i really wanted it to serve media, so I needed to install MediaTomb (not TwonkyServer, 'cause you have to pay for that, and I hear it's poorly supported).

In order to install MediaTomb, I used Fun Plug. Installing Fun Plug was easy, all it takes is downloading the latest tarball and executable (fun_plug and fun_plug.tgz), dumping them onto the mounted volume (typically /mnt/HD_a2/), rebooting, and grabbing the latest packages and installing them.

After restarting, you'll want to run the following commands, which will grab all the latest Fun Plug packages over rsync. If you see a funny message about ssh keys and the like, you probably screwed up the syntax of the rsync call. I did the first time 'round. Note that Fun Plug usually sticks itself in /mnt/HD_a2/ffp.

cd /mnt/HD_a2/ffp
rsync -av inreto.de::dns323/fun-plug/0.5/packages ./
cd packages
funpkg -i *.tgz

Grab the mediatomb tarball from here: http://www.mediafire.com/?3ndu9sdn3z1

Extract it, then run the following commands to get it all started:

LD_LIBRARY_PATH=/mnt/HD_a2/mediatomb/lib; export LD_LIBRARY_PATH
/mnt/HD_a2/meditomb/bin/mediatomb -d -e egiga0 -p 49152 -m /mnt/HD_a2/mediatomb

You also might have to chmod a+x the mediatomb binary to make it executable before all of this will work.[1]

I changed some of the settings in /mnt/HD_a2/mediatomb/.mediatomb/config.xml to better match my personal preferences, like the way it organizes media and what to call itself, but that's not terribly difficult and the documentation for MediaTomb is pretty good.

Navigating to http://yournasip:49152/ will give you the MediaTomb configuration page (which lets people access your entire filesystem, so unless you're okay with that, I wouldn't open that port to the internet). You can add which folders to watch there, pretty easily.

Note that mediatomb will only scan folders every half hour or so (and it takes FOREVER and half to do the initial spidering of your library), so don't expect lighting updates like you get from WMP 11.

  1. Thanks to Ian of http://www.futurehat.com/