File Server Builder's Guide
by Zach Throckmorton on September 4, 2011 3:30 PM ESTWhile the focus of this guide is hardware, it's worth first briefly discussing home file server operating system options.
Windows Home Server 2011
Microsoft launched its latest version of WHS earlier this year. It can regularly be found for $50 or less when it's on sale. Of all the file server operating systems available, WHS2011 is the easiest to both set up and administer for users familiar with the Windows series of desktop operating systems and less familiar with Unix or Linux. If you've installed and configured Windows XP, Vista, or 7, you can install and configure WHS2011 with a minimal (or even no) extra research. The downside to this ease of use for the home file server novice is, of course, cost - WHS2011 is not free.

FreeBSD and FreeNAS
FreeBSD is, of course, free. Because it is a Unix operating system, it requires time and effort to learn how to use. While its installation uses an old text-based system and its interface is command line-based, you can administer it from a Windows PC using a terminal like PuTTY. I generally do not recommend FreeBSD to users unfamiliar with Unix. However, if you are intrigued by the world of Unix and are interested in making your first foray into a non-Windows OS, setting up a file server is a relatively easy learning experience compared to other Unix projects.
FreeNAS is based on FreeBSD but is built specifically to run as a file server. It features an intuitive, easy to use web interface as well as a command line interface. Both FreeBSD and FreeNAS support ZFS, a file system like NTFS and FAT32. ZFS offers many benefits to NTFS such as functionally (for the home user) limitless file and partition size caps, autorepair, and RAID-Z. Though it is aimed more at enterprise and commercial users than consumers, Matt wrote an article that has lots of useful information about ZFS last year.
Ubuntu and Samba
Ubuntu is arguably the easiest Linux distribution for Windows users to learn how to use. Unsurprisingly, then, it has the largest install base of any Linux distro at over 12 million. While there is an Ubuntu Server Edition, one of the easiest ways to turn Ubuntu into a home file server is to install and use Samba. (Samba can be used on not only Ubuntu, but also FreeBSD.) Samba is especially useful if you'll have mixed clients (i.e. Windows, OS X, and Unix/Linux) using your home file server. Though FreeNAS certainly works with Windows clients, Samba sets the standard for seamless integration with Windows and interoperability is one of its foci.

Succinctly, WHS2011 is very easy to use, but costs money. Installing Ubuntu and Samba is not particularly difficult, and even if you've never used any type of Linux before, you can likely have a Samba home file server up and running in a morning or afternoon. FreeNAS is arguably a bit more challenging than Ubuntu with Samba but still within a few hours' grasp of the beginner. FreeBSD is potentially far more capable than WHS, Ubuntu/Samba, and FreeNAS, but many of its features are mostly irrelevant to a home file server and its learning curve is fairly steep. When properly configured, all of the above solutions are sufficiently secure for a typical home user. Most importantly, all of these options just plain work for a home file server. An extensive comparison of each OS's pros and cons in the context of a home file server is beyond the scope of this article, but now that we've covered a few OS options worth your consideration, let's get to the hardware!



150 Comments
View All Comments
pvdw - Monday, September 05, 2011 - link
But you should have a good quality PSU to give nice clean, reliable current. Loads of PSUs are just rubbish. ReplyLonyo - Sunday, September 04, 2011 - link
You may have mentioned needing a good power supply, but when you talk about Atom and Zacate boards, low power solutions, and low power "green" drives, you don't focus on the fact that total system power use in typical conditions could be lower than 30w. If you are buying a beefy 500w power supply, you could be wasting a LOT of power due to efficiency issues.The 80PLUS rating only tests as low as 20% of full load. 30w on a 500w PSU is below 10% load, so you could be getting 70% efficiency.
While it's not a major concern, if you are looking to make things low power to leave it on 24/7, you might want to think about some DC power supplies rather than regular desktop power supplies.
If you are making a 2~4 drive file server based on an Atom system, you could get a 100~120w picoPSU instead of a "real" PSU, and get potentially much higher efficiency than with a 300w+ normal PSU.
Of course, not everyone (especially Americans) cares about efficiency, since for them power is so inexpensive, but for a 24/7 box, why not at least discuss things which might improve power efficiency? Reply
jtag - Sunday, September 04, 2011 - link
I have to say that a file server guide that mentions RAID/NAS really should include a discussion on which drives are suitable for using in a RAID. Not all drives are valid for use in a RAID, not because of reliability concerns, but rather because not all manufacturers support Error Recovery Control (see http://www.csc.liv.ac.uk/~greg/projects/erc/ for more info) in their consumer level drives.I'd very much appreciate it if AnandTech could run the following command on every drive they test and add it to bench, so we could come up with a list of drives that do support ERC:
smartctl -l scterc /dev/sdX
smartctl is available for both Windows and Linux (smartmontools.)
Of course, this may say it is supported, but the real test would be to set timeouts:
smartctl -l scterc,70,70 /dev/sdX
And then cause the drive to have a block error and see if access times out, or causes the drive to drop out of the RAID. This would also be a good test of RAID controller cards, though personally I always use software RAID under Linux. Reply
jtag - Sunday, September 04, 2011 - link
And for the record - I run 6 2TB drives in a RAID-6 (2 drive redundancy) with one hot spare under Gentoo Linux software RAID. My drives are 5 Seagate ST32000542AS and one Samsung EcoGreen F4 HD204UI Replyjwilliams4200 - Sunday, September 04, 2011 - link
Any tips on how to "cause the drive to have a block error"? ReplyRick83 - Monday, September 05, 2011 - link
you can use hdparm to mark a block as faulty, IIRC. Replyjtag - Monday, September 05, 2011 - link
Exactly so: hdparm --make-bad-sectorThis is "Exceptionally dangerous. Do not use this option!!" according to the man page, which goes on to say "This can be useful for testing of device/RAID error recovery mechanisms." Reply
pvdw - Sunday, September 04, 2011 - link
The best case I've found for a 4+ HDD SFF home server is the Lian Li PC-Q08. For me sound and size are most important.http://www.silentpcreview.com/Silent_Home_Server_B...
BTW, Linux has some significant advantages over WHS when used for more than just a file server. But I'll leave those for you look up. Reply
pvdw - Sunday, September 04, 2011 - link
BTW, I forgot to mention some things about my configuration.Linux RAID-1+0 far copies
Automated local backups using hard-links
Auto-rotation of backups
Auto-rsync to single remote backup
VPN Server (not finished setting up yet as has become a lower priority)
Print Server
Torrent server (Transmission)
Webserver (web dev environment)
SSH
Most of that is more than you'll need, but I'd definitely recommend at least RAID1 and auto-backups for a file server. Reply
bobbozzo - Wednesday, September 07, 2011 - link
A hard-link 'backup' won't protect you if the file is modified or corrupted. Reply