To NAS or Not To NAS

A NAS (Network Attached Storage) comes in many different guises. From a single drive box that you connect to your router at home to something containing many disks that may be sited in a datacenter somewhere, the principal is the same;  storage that you can access from any computer on your network to store and retrieve stuff.

I have a NAS at home.  It is a D-Link DNS-345.  It contains four hard disk drives of 2TB (terabytes) each.  The disks are configured as a RAID 5 pack providing a shade under 6TB of available storage… and it’s nearly full! (for the techies out there; we can talk about the RAID 5 hole in another discussion…)

Our main TV at home is based on Microsoft Windows Media Center delivered from a Windows 7 box.  All the box does is entertainment- TV, Photo’s, Music, etc.  I have theMicrosoft remote control and keyboard and it just works.  I have tried other solutions, but frankly, with all of the pro’s for these other solutions (free is a big plus), they have never really cut it.  They keep missing something – “Here’s all of your media and your recorded DVD’s.  Oh, you want live TV and an integrated electronic programme guide (EPG)?  We can do that.  Just follow these (ridiculously convoluted, confusing and long winded) instructions and you’re good to go.” – except, you never are…

I digress…

My TV is based on a PC and I am a bloke.  Being a bloke means that I collect things.  Having a digital PVR means that I can record things: The full series of M*A*S*H, Family Guy, Star Trek – all of ’em, Dad’s Army, the original Dr Who, etc, etc, etc..  So, I have a lot of stuff stored…

Oh, and I take photo’s.  And I don’t delete photo’s.  Currently at 66,000 and counting – that’s only(!) 400GB. but it’s still a lot of my digital life.

My photos and documents are stored on my Windows Home Server and then backed up to my NAS.  This gives me a reasonable level of resilience as nobody in my house is allowed to use the NAS – are you reading this Jake! So, when The Boy introduces another virus into my network, I have a fighting chance that I will have something left in one piece, somewhere.

But what about a fire?

What about theft?

Well, the NAS is hidden, but it won’t stop the fire.  I need to get the data off site.

But I can’t afford 6TB and growing of cloud storage…

Perhaps I am not the only person for looking for offsite storage that is more than just taking a USB drive offsite.  Perhaps this is something that I can investigate as a product for you, friends of CAAOS.

A little bit of investigation and thought and I have decided that, even with my slight OCD tendencies to storing entire series of old programmes, I should probably just consider the important stuff; My photos, videos and documents.  TV isn’t that important.  Downloaded programs aren’t important.  Personally created stuff is… That means it is well worth me investigating and implementing a solution that will live “somewhere else” and allow for automated, remote, secure backups.

Lots of looking and a few trials and I have settled on FreeNAS

Some of you may have seriously investigated or be running FreeNAS and will have some very definite views on ECC RAM and ZFS.  Before you send the flames and the arguments and the whatever in the comments, please note the following:

  • I get it
  • I have read most of what is out there that isn’t a repeat of everything else that is out there
  • I have sat down and thought about it
  • I AM NOT GOING TO USE ECC RAM!

If you don’t know why I have written that little bulleted list, I will create a bunch of links that explain a little bit about what ECC is, ZFS is and why I have chosen the route I have chosen.  You may also get a sense of the feeling out there!

Using a virtual machine on the Shop’s LGA 2011 i7 based PC (what!, you haven’t seen it yet..? I’ll post the specs sometime), I have created a VM running FreeNAS and have attached 4 x 20GB virtual drives.  I plan to set up a ZFS based RAID-Z2 pack.  With 4 drives, that gives you 2 disks of data and 2 disks for parity (RAID-Z2 on Wikipedia scroll down to ZFS).  I then created a second lot of disks to experiment with expanding the volume.  This worked.

I then deleted one of the virtual disks from the virtual machine and restarted it. It continued to work.  I then created a new, 40GB virtual disk and added that into the pack to show the replacement of a failed drive.  That worked.  Next is to experiment with increasing the size of all drives so that I can ultimately increase the size of the volume.

Happy with the functionality of the system, I have now bought some hardware and have built a FreeNAS box.  Specs;

  • Gigabyte GA-Z97P-D3 S1150 Z97 ATX Motherboard
  • Intel Pentium G3220 3.0GHz Dual Core 1150 processor
  • 1 x 8GB DDR3 Non-ECC (Max 32GB) [contain yourself now]
  • Chieftec A-80 Series ATX Power Supply 650W
  • Antec VSK-4000E 3-Bay ATX Black Case 12cm Fans
  • 16GB Kingston DTIG4 USB Stick (for the OS)

In terms of disks, I am having to upgrade the the disks in my home NAS to 4TB each , so I am taking the 2TB Western Digital Greens from there to put in the first build of this FreeNAS box.  To do this, I am replacing one drive at a time and allowing the drive to rebuild.  The rebuild takes about 17 hours – per disk. I am on disk two as I write.

Ultimately, I will replace these disks with Western Digital Reds x 4GB.  The motherboard was chosen because it has space for 6 x SATA3 drives and few PCI-E lanes that I can put extra drive controllers on if I wish. It also has 4 x DDR 3 slots, hence the max of 32GB.  The case will take ten drives!!  So, this is being built with a mind to production rather than just R&D!!

Why the 16GB USB stick?

FreeNAS is designed to run from an 8GB USB stick.  The advise is to go bigger.  Other builders have used a small SSD to improve on start up time. Basically, there is little to no writing to the OS drive during normal operation.  Using a USB stick means that I don’t have to use an expensive drive and, more importantly, SATA port.  The OS drive cannot be used for storage, so anything buigger than 16GB is just wasted space.

A  quick look around my shop and a some checking of stats on the interweb put the DTIG4 stick as the fastest for reading… which would make it the fastest to start up without SATA.  I have taken a USB bracket that plugs directly into the motherboard USB header and taped the stick to the inside of the case using VHB tape from 3M – apart from catastrophic failure of the case, I will never need to touch it.  Also, it removes the “risk” of somebody pulling it out while operating.

and, no optical disk

Well, that’s it for now…

The next stage is to set up SSH and RSYNC as well as get some security certificates established to enable secure communications from my house to the shop.  I am also playing around with a free bit of software called Duplicati which enables encrypted, secure backups from a Windows, Mac or Linux to an SFTP server, external drive whatever…..

As soon as I get some more info for you, I will post back to the blog.  I will put this into a category of Storage so you can find it in future.

Have fun,

Gary

ECC or Non-ECC: The great debate:

Leave a Reply

Your email address will not be published. Required fields are marked *