Introduction
Network Attached Storage - otherwise referred to as NAS - is probably the best way to add storage that is generally available across your LAN. Possible uses for a NAS device are as varied as the myriad of choices of hardware made to support it. You can use one solely as an automatic backup device, share videos and music across the LAN, or even stream content to a HTPC.
Yeah, you can buy pre-built devices the size of a hardcover book, but what fun is that? The reason I'm building one is that I need to automate backups of four systems in my house. I don't want to have to think about it beyond the initial setup. I'm also tired of burning DVD's (I've probably spent thousands of dollars on blank media). Sure, an occasional backup to DVD is probably warranted, but not <b>every</b> backup. It's a pain, and I have to baby-sit the process. No thanks.
<b>Note:</b> This article deals expressly within the realm of a trusted networking environment where you don't have to worry about local intruders (your kids and their friends), idiot users (your spouse and your friends), and your LAN is not exposed in any way to external access (the internet). Also, my intended use is currently just a way to conveniently store incremental backups and the occasional restore point for all of my machines.
If you intend to share files (videos and music) across your LAN, you're pretty much on your own as far as adequate hardware is concerned, but I suspect that everything I say below is applicable to the most extreme usage. Now, let's get on with the show.

Building a NAS Device
Why would you want to? There are several commercial items available, ranging from simple single-disk units targeted at home networks to veritable behemoths, supporting as many as a dozen drives in a single rack. The more money you spend, the more capable the pre-built NAS is. The same is also true of a homemade NAS device, although you automatically start out over-spec'd because I assume that like me, you'd be using fairly modern hardware (even if you start out with used hardware).
As far as pre-built units are concerned, I've found (by reading user reviews of various devices) that service is spotty, reliability is a crap shoot, and anything even remotely adequate starts at about the $500 price range, and that's for a diskless 4-disk NAS device that supports RAID 0, 1, 5, 10, and JBOD, and allows hot-swapping and unlimited (but variable) drive sizes. Remember, you've spent $500 so far and STILL don't have any drives installed in it. If that's the case, then why not build it yourself? After all, a NAS is nothing more than a dedicated file server, right?
Chances are pretty good that you have some almost-ancient hardware laying around. You know, that box that nobody wants because it's got a single-core CPU in it and only 512mb of ram, a machine that wouldn't boot Vista on a bet, and is barely usable under Windows XP. Say hello to your soon-to-be home-made NAS device. However, before you press that old 386 system into service as a NAS device, there are several aspects you should consider.

Considerations
Before building your own NAS, there are a few things you have to consider. Since it's probably going to be powered up 24/7, you have to think about power consumption, heat, and noise. A typical workstation-class computer consumes considerable electricity, and generates a moderate amount of heat, despite making enough noise to wake the dead in an attempt to evacuate the heat. Next, how much space is it going to consume, and just where the hell do you put something like that?
Power Consumption and Heat
Your primary goal should be to reduce power consumption, because that cascades into an overall reduction in heat (and noise). At the same time, you don't want to sacrifice too much performance in your quest for arctic-like temperatures. Here are some general tips to reduce power consumption:
- Use a lower-performance CPU. Pay attention to the power/thermal characteristics of the CPU. Historically, AMD's Athlon64 CPUs have generated less heat than comparable units from Intel. Besides, you're only running a NAS, not a full-blown server. You simply don't need the juice afforded by faster CPUs.
- Use as small of a device as possible to boot the system. There are several options available to you that we'll discuss a little later in this article.
- Use an unimpressive video card. It only has to provide enough features to drive your monitor. Don't use one that requires one or more power connections from the PSU, or that requires a fan to cool it. You're running a NAS, not a gaming machine. After the initial setup, you may not even need a monitor connected to the device.
- If you can, get a case that has at least two 120mm fan openings (one at the front, and one at the back). Evacuating heat from your system is the key to allowing it a long and useful life. Cases like this can be had for as little as $50 from NewEgg.
Noise
If there's one thing you don't want from your NAS, it's noise. You'll have as many as four (or more) hard drives in the box, a power supply fan, (maybe) a CPU fan, and at least a case exhaust fan. You might even have a case intake fan. All of these items can add up to a very loud system unless you take steps.
Putting the drives on power-save mode where they spin down during periods of inactivity will reduce the noise level (and heat). Putting a fan rheostat panel in the machine will allow you to reduce the rotation speed of your fans, thus making them more quiet. Under-clocking the CPU may allow you to even eliminate a fan. To reduce the fan noise, make sure your system uses nothing but 120mm fans. They're bigger, and move more air at lower speeds. A 120mm fan rotating slower than it's maximum speed usually moves more air than a smaller fan at it's maximum speed.
One other tip is to replace the fans that come in the case with higher-performance fans. They move more air and are much more quiet than the fans that come in computer cases. The key is to get the quietest fan that moves the most air when operated at 12 volts. A fan rheostat will allow you t dial down the speed without sacrificing too much air movement.
Visibility
Using a computer as the basis for a NAS means the case is gong to be - well - huge, especially when you compare the that to a pre-made NAS. Make sure you have the floor space to stand it up. A mid-tower case is not a bad thing because it promotes better cooling and the possibility of using passively cooled components. Obviously, this is going to reduce the noise level and power consumption as well.
Hardware Recommendations
I realize I started out talking about using old hardware that you have just laying around, and that's still a very viable option, but when you throw the heat/power considerations at your ancient hardware, you must certainly realize that power/heat ratios will be worse with old hardware because they simply didn't have the technology to address those things as well back in the day those components were built.
Further, old motherboards don't have SATA2 connectors, forcing you to buy a SATA2 controller card, and most probably in the lower performing PCI form factor. The PCI bus is notoriously narrow, so you'll be throttling the performance of your NAS, and believe me, if you're doing anything other than backups, this will not be a "good thing"(tm).

Do yourself a favor and build a new box. It's not nearly as expensive as you might think it is. I just build a COMPLETE system for my sister that cost less than $400 (AM2 single-core 45w CPU, 2GB RAM and a nVidia 8400GS video card). The motherboard I chose for her wouldn't be a good NAS candidate because it only has two SATA connectors, but there are an adequate number of motherboards with the correct specs and almost as cheap.
For a NAS device, I would pick a motherboard with four SATA2 connectors, at least three PCIe slots, built-in video, and built-in gigabit LAN, as well as support for at least 4gb of RAM.
You can save a lot of money buying a motherboard with the required built-in components, but be sure to keep an eye on compatibility with your chosen NAS software. A modern system should provide a sustained minimum transfer rate of 8MBs on a 100Mb LAN, and that's a LOT better than many of the lower-end pre-built NAS devices.
Pre-NAS Configuration
In my case, I have a complete system that is so unused that it had been unplugged and retired to the closet. The system is comprised of the following components.
The Computer Case
This system is built inside a Rosewill R5604-BK mid-tower case that provides 120mm fan openings for both intake and exhaust. Yay! This case cost me all of $55 when I bought it a couple of years ago. It also provides a flip-up cover that exposes front-panel USB and Firewire400 ports. Convenient, but probably not necessary. There is room for four external (5-1/4 inch) drives and four internal 3.5-inch drives. This case is screwless, so installing and removing drives will be a bit less of a hassle. I will be keeping this component.
Power Supply
For a device that will be powered up 24/7, you need a reasonably high-quality and reliable power supply. The one in my system is a CoolerMax unit providing a maximum of 430 watts to the system (far above the presumed needs). It also has a number of SATA power connectors. I will be keeping this component.
The Motherboard
The motherboard is an ASRock 939Dual-SATA2, and has the following NAS-related specs:
- Socket 939 for AMD Athlon™ 64FX / 64X2 / 64 processors
- FSB 1000 MHz (2.0GT/s)
- Supports HyperTransport and AMD Cool'n'Quiet (key feature)
Memory:
- Up to 4GB of Dual Channel DDR (DDR400 non-ECC, un-buffered) memory technology
- Realtek RTL8201CL 10/100 Ethernet LAN, supporting 802.3u, Wake-On-Lan
- 1 x AGP8X/4X slot , 1.5V only
- PCI Express x16 slot
- PCI Express x1 slot
- 3 x PCI slots
- 2 x SerialATA connectors support RAID,0,1,JBOD
- 1 x SATA2 connector (based on PCI E SATA2 controller JMB360)
- 2 x ATA 133/100/66 IDE connectors (supports 4 x IDE devices)
- 1 x Floppy connector
- 2 x USB 2.0 port pin headers (to support extra 4 USB2.0 ports)
External (rear panel) ports:
- 4 x USB2.0 ports
- 1 x RJ45 LAN port
- 1 x Serial port (COM1)
- 1 x PS2 Keyboard connector
- 1 x PS2 Mouse connectors
- 1 x Parallel port (LPT1)
What's really cool about this motherboard is that I can run a AGP video card, leaving the PCI Express slots available for other cards with more demanding throughput needs. I can also upgrade to an AM2 CPU that consumes less power. I probably won't be doing this since throwing money at this motherboard is beyond pointless given the nature of it's availability.
Initially, I decided to just use the single SATA2 connector on the motherboard, more as a test than anything else. Eventually, I'm going to replace the motherboard with something that has built-in video and LAN, and at least four SATA2 connectors. Reducing the hardware in the box is always a good thing, and a new motherboard like I described will allow me to get rid of the 3Com NIC and the video card (less heat, less power consumption).
I won't be needing the on-board SATA1 ports. In fact, the on-board SATA1 controllers are disabled, as is the floppy controller. I had to keep both of the IDE controllers enabled so that I can a) boot the system, and b) install software from a CD. Actually, I could even get a IDE-to-USB converter and just plug the DVD drive in as needed, thus allowing me to disable the 2nd IDE channel, but that means two more wires hanging around outside the machine. I also don't need the serial, parallel, or sound functionality, so those are disabled as well. I'm not sure if this will affect the power needed by the motherboard, but there's really no point in having this stuff enabled if I'm not going to need it.
The CPU
I'm very fortunate to already have an acceptable CPU. It's a single-core Winchester-based AMD64 3200+ that runs at 2.0ghz. While a dual-core chip would provide better performance, the single-core consumes less power (and makes less heat). It's also almost 3 times as powerful as the CPUs used in your typical pre-built NAS device. This means I can under-clock it and STILL have something with more oomph than a pre-built NAS. I may even be able to get by with a passive cooing system for it. The motherboard also supports the AMD Cool-n-Quiet functionality of the CPU, so it can reduce power when the CPU is idle.
Memory
The system currently contains two 512mb sticks of memory. Less memory would present a better heat/power profile, but I'm not sure what kind of memeory requirements I'll have to deal with. Again, we're only running a NAS here, not a gamer/workstation box. For now, I'll be keeping the memory that's in the box.
The Video Card
One of the advantages of using the motherboard that's in this box is that you can run a AGP video card OR a PCIe video card in it. Using a AGP card frees up the PCIe slots for cards that can actually improve the performance of the system due to higher available throughput, such as an appropriate add-on SATA2 controller. The system already utilizes a passively cooled ATI Radeon 9200. I'm not a fan of ATI, and the 9200 really is much more powerful than is necessary, but I'll be keeping it for now.

The NIC Card
The motherboard has it's own LAN connector, but I added a 3Com 905TX when I originally built the system because I don't inherently trust built-in components on motherboards. I know, that's a weird and completely unfounded attitude. However, the card is well-supported in Linux and FreeBSD, so to avoid hassles, I use it. I'll be keeping this component until I upgrade the rest of the network to Gigabit status.
Storage
The system current contains a pair of 80gb hard drives and a DVD-Rom. The hard drives will be removed and replaced with an alternative boot device (discussed below, and the DVD player will remain to allow installation/update of the NAS software..
Cooling
The system is currently equipped with a brace of 120mm cooling fans - one for exhaust, one for intake, and one for the CPU. All of these are controlled by a fan rheostat panel. When building the box, I purchased the fans for their low noise levels and the amount of air they move. Each fan was about $20.
Making The System a NAS
To make my existing system a NAS, I have to change out some of the components. Fortunately for me, the list is quite small.
The Boot Device
First, I need to remove the original hard drives and install something to boot from. The idea is to use something that doesn't make heat, and doesn't use much power (I can't stress this enough).
Since most of the NAS software out there consumes so little hard drive space, you may be able to get away with using an IDE flash drive/CF card combination. This, of course, depends on which NAS software you've chosen. The typical flash drive plugs directly into your motherboard's IDE connector, and a Compact Flash card is then inserted to act as an IDE hard drive. The cost of a flash drive and a reasonably large/fast CF card is around $60.
The only downside to using a Compact Flash drive is that it doesn't support DMA (without a hardware mod to the flash drive itself), and will therefore adversely affect the performance of the system. Granted, the flash drive will only be used to boot the system and modify configuration files, but for me, any performance hit is simply unacceptable when there are better options available.
In my case, I have a couple of old 2.5 inch IDE hard drives that were removed from laptops. The one I'll be using is a Hitachi TravelStar that spins at 4200 RPM. The model number is IC25N020ATMR04-0, and it was manufactured in January 2004. The benefit of using this drive is that I can get a 2.5-3.5 converter for just $5 from NewEgg (saving $55 because I don't have to get the flash drive/card), and it's capacity is much higher than any affordable flash card.
The only downside is that since it's a hard drive, it will consume more power and make more heat than a flash/CF drive. However, being a laptop hard drive, it certainly consumes a lot less power and makes a lot less heat than a typical desktop hard drive. I think the trade-off is worth it, especially when you factor in the better performance as well. You can find used laptop drives for as little as $20 on EBay, and ranging in size from 20-gb up to 160gb (definitely overkill). If you go this route, try to stick with the 4200rpm or 5400rpm drives because they use less power and make less heat.
Lastly, if your motherboard allows you to boot from a USB device, you can use a USB stick to store the NAS software. I don't see this as being nearly as worry-free as having an internal boot device, so I chose not to go this way.
Storage
Okay, this is the big cahuna. Remember, the motherboard I'm using already has two SATA1 connectors, and one SATA2 connector built-in. Since disk performance is one of my primary goals, the SATA1 connectors are automatically eliminated from the "usable" category. Also, there is only one SATA2 connector, effectively eliminating the use of more than one SATA2 drive.
Not only that, but having only one SATA2 drive eliminates the possibility of using RAID. Finally, I don't like built-in components due to the possibility of failure and compatibility issues. The card I've chosen is a PCI Express Highpoint RocketRAID 2300, and runs $110 at NewEgg.
For those reasons, I feel that it's best to go ahead and purchase an add-on RAID-capable SATA2 controller that supports at least four drives. This pretty well future-proofs your NAS, even if you don't use all the capabilities of the card.
Next, you have to select the actual hard drives. The best advice I can give you is buy the biggest drive you can possibly afford. If you're sharing files on the LAN (videos, music, etc) your hard drive space will get chewed up faster than you can say "V for Vendetta". If you're using your NAS to hold backups, your storage needs are considerably less dramatic since most of the time, you'll be performing incremental backups.
For my initial setup, I got a 500gb drive (about $95 if you get an OEM drive).

Old Or New?
So, should you use old hardware, or new hardware. There are pros and cons to both approaches.
Old hardware is probably going to be more compatible with the Linux/BSD kernel. This is a big benefit to using old hardware, but there really is no guarantee that Linux/BSD will support YOUR hardware. This biggest con about using old hardware is performance. If the motherboard doesn't have PCIe and SATA2 built in, your disk throughput will suffer, sometimes dramatically so.
New hardware's biggest benefit is that you'll be able to exploit much faster CPUs, more (and higher-performing) memory, and higher storage throughput. However, compatibility with Linux/BSD may not be as thorough (right now).
As you can see, you must take steps to ensure hat your selected hardware can run under Linux/BSD. Check their Hardware Compatibility Lists, scan the appropriate forums, and pray that you made the correct hardware buying decisions.
Other Hardware Notes
I would recommend that you buy a spare NIC, SATA2 Controller card, and hard drive, just in case something fails. It's hell when you have to wait a week (or more) for the UPS guy to show up with replacement parts.
I also HIGHLY recommend that you get a UPS for the NAS. Most NAS software features UPS-handling code that will perform a controlled shutdown of your box in the event of a power outage. It doesn't have to be a monster UPS (probably a 600/650 will do), and it's really cheap insurance against damage.
NAS Software
There are a few free packages available that turn your system into a NAS device, but the three that seem to get the most use are FreeNAS, OpenFiler, and NASLite. Since my use is restricted to a home network for the purposes of storing backups of my other systems, I chose FreeNAS.
NASLite was a viable candidate until I found out that it doesn't have a webGUI interface. We're well into the 21st century, and there's absolutely no reason to settle for a Telnet interface in this day and age. Besides that, it costs money - not a lot of money ($30), but money nonetheless. Finally, the HCL seemed to be lacking in my view.
OpenFiler exerts a much heavier footprint in terms of OS image, and is in fact a full-blown Linux distro that consumes about 500mb of space when installed. It also has a lot of heavy-duty features such as quotas, user and group management, and other enterprise features. This also makes it more difficult to use from a hobbyist/home LAN admin standpoint. If you're up to it, I'd definitely recommend using this package.
FreeNAS is a small-footprint (about 40mb) distro based on FreeBSD. It's reasonably feature rich, and development is on-going. There is also a very active user community, with the code and forums being hosted on SourceForge. This software was my choice due to it's lighter footprint, ease of use, and availablity of user-based help via the forums.
FreeNAS
Using FreeNAS is a piece of cake. Just download the ISO, burn it to a CD, and boot your soon-to-be NAS machine from the CD. Assuming you've done your homework and selected the most compatible hardware you can find, FreeNAS should install in less then a minute onto your boot device. It's really just that simple. When you get the FreeNAS splash screen, wait for the little audible tweeter sound, and press Enter. At this point you will be presented with a text-based menu that allows you to configure the system. Here are the default settings you need to know:
Static IP address: 192.168.1.250
User ID: admin
Password: freenas
You can change all of the settings available in the menu from the WebGUI, so just open your browser and browse to the IP address shown above. You will be prompted for the admin user ID and password, and upon providing that info, you will be presented with the FreeNAS webGUI.
From this point on, I must refer you to the documentation and FreeNAS support system. Have a ball with your new NAS. The reason is because you're probably going to use your NAS differently than I do mine. I will say, however, that I chose NFS for the disk format, and enabled CIFS. If you're using Vista workstations, remember to disable "Allow null passwords" in the CIFS setup.
The only thing I wish FreeNAS had was printer server capability. I'd love to dump my Keyspan print server device because it doesn't have (and the manufacturer isn't planning to have) any 64-bit driver support.
Where To Get Stuff
For those of you that suffer from a complete absence of the "google" gene, here are some links that are bound to go bad sometime in the future.
FreeNAS
OpenFiler
NASLite