FreeNAS versus unRAID as the operating-system for a DIY NAS? - Printable Version
+- XBMC Community Forum (http://forum.xbmc.org)
+-- Forum: Off-Topic (/forumdisplay.php?fid=34)
+--- Forum: Hardware for XBMC (/forumdisplay.php?fid=112)
+--- Thread: FreeNAS versus unRAID as the operating-system for a DIY NAS? (/showthread.php?tid=82811)
- froggit - 2010-10-12 22:57
BLKMGK Wrote:A standard RAID can lose a disk and not lose data. However losing TWO disks often means losing ALL data unless you've added still more disks to the array for redundancy.
I can't say for all RAID systems, but with ZFS you can choose your preferred level of redundancy. For example, if you're happy with the capacity of one disk for parity data then you could choose a simple 2-drive mirror, or RAID-Z1. If you want more safety then you can choose double-parity like RAID-Z2. If you want triple-parity then you can choose RAID-Z3, which allows three drives to fail before you lose any data.
So depending on your wallet / paranoia level, you can choose a level of data safety that suits your own situation.
BLKMGK Wrote:Likewise a standard RAID spans files across many disks - the advantage being FAST data access as you get data from multiple disks at once. However this means they all must spin to get access to the data. unRAID doesn't span disks like that and stores parity on a dedicated drive with other drives using REISERfs which is a standard F/S. Downside being that the array doesn't appear as a giant volume (shares take care of this) and that it's not as fast. However for spitting out even the highest def video you do NOT need uber fast transfer rates so this is good. unRAID is NOT meant for enterprise storage, it's meant for home media primarily and it serves this purpose VERY well.
Why not use enterprise-level data safety mechanisms that are *free* and available within ZFS? What happens with unRAID if your parity drive dies, or one or two of your data drives dies? With ZFS, using RAID-Z2, if *any* one or two drives die you lose no data, and you can rebuild any dead drives so *no* data is lost.
BLKMGK Wrote:ZFS I cannot speak to. I have researched it some because it's always something put forth as a solution but I'm not sure how you would set this up booting from a USB stick etc.
USB sticks are not generally suitable for booting OS's from as they tend to write frequently to the devices (logs etc), and this will reduce the life of the USB stick. They are also fairly slow to boot from.
BLKMGK Wrote:and I think Solaris x86 and BSD (?) are the only ones with real support. Solaris is a bit shaky so far as corporate support right now I think and i'm not sure how friendly BSD is. unRAID however is pretty simple I think and lots of folks are on the suport forum willing to help...
Solaris has corporate support from Oracle.
Also, for ZFS newbies there is a great forum available on the OpenSolaris.org site which is frequented by very knowledgeable & helpful ZFS users - see here, including Oracle staffers: http://opensolaris.org/jive/forum.jspa?forumID=80
ZFS is simple - here I will create a 6-drive array which can survive any two drives failing before any data is lost:
# zpool create tank RAID-Z2 drive1 drive2 drive3 drive4 drive5 drive6
Now we'll create a file system to store our movies in:
# zfs create tank/movies
Now we'll create a 'share' so that our movies can be shared to other devices like computers around the home, or HTPC / media center:
# zfs set sharesmb=on tank/movies
Voila, what's hard about that?
Now, for one of the killer features of ZFS, that virtually no other RAID system has -- the ability to find and repair all files that have become corrupt due to 'bit rot':
# zpool scrub tank
This last command will read the contents of *all* files within your storage system and compare each block with a 256-bit block checksum. Any blocks not matching the checksum will be recovered by using the parity data stored when the file was originally created. This feature is priceless and gives you peace of mind that your data is 100% correct as it should be. Can unRAID or FreeNAS do that?
- froggit - 2010-10-12 23:18
BLKMGK Wrote:Froggit - does ZFS require all disks spinning in order to make a write or read?
Not if the data is in cache. ZFS uses available free memory to store files read.
However, it will need to spin the drives if data is not in cache.
BLKMGK Wrote:If so I would argue that this is a downside since that means more energy used.
However, for energy reduction, you may use the OS power management features to spin-down drives after a set time period like 5 minutes, and a lot of the 'green' drives auto-park heads for reduced power usage anyway.
BLKMGK Wrote:Likewise if it needs 2 disks for parity to recover data on a dual failure that's not good. I'm wiling to lose data on a dual failure - 2 disks worth - but NOT an entire array of say 16 drives.
You are very generous. I am not willing to lose any data. And the price of 2 drives to give peace of mind helps me sleep really well. And I have a backup of everything.
BLKMGK Wrote:ZFS sounds attractive for many things from what I have read but I have not yet heard anything compelling over unRAID. Especially if it also requires an OS disk rather than booting from USB and giving me as much storage as possible. I can run from 2-16 disks in my array and never lose more than a single disk to parity overhead and nothing to OS overhead...
Read my previous reply about ZFS to get an idea of how easy it is to use and setup, and the data safety mechanisms built in. You can look at parity data a bit like insurance: have no parity data and you lose data when drive(s) die, have parity data and your loss is zero to low, depending on how much parity data you have and how many drives die. It's not rocket science. Once this is understood well, one can plan the level of safety required.
- froggit - 2010-10-12 23:34
poofyhairguy Wrote:I would argue that Unraid gives less of a chance for data loss because you can mix and match different hard drive sizes and vendors over the course of months to grow your array, while ZFS requires you to have all the hard drives wanted in the array when you first build the system.
That's not true. With ZFS you can add a 'vdev' to your existing pool. A vdev (virtual device) is a group of drives - like a 2-drive mirror, to a multi-drive RAID-Z3 array. It's up to you. What you are probably confused about is that you can't expand an existing vdev, although you can replace each drive with a larger one, so you can expand an existing vdev in terms of capacity but not expand the number of drives within an existing vdev.
poofyhairguy Wrote:Unless you go out of your way to buy the same hard drives from different vendors, then you are basically gonna buy all your HDs from the same batch. If that batch was defective then there is a change you can EASILY lose more than two drives at a time and all your data is down the tubes. For an enterprise you buy enterprise drives to avoid that, but most of us are using consumer drives. That makes ZFS a liability.
You can mix drives from different manufacturers if you want to with ZFS. Personally I prefer to research reliable consumer drives and use this when making ZFS storage servers, but different people do different things.
poofyhairguy Wrote:With Unraid the only way more than one HD is going down at one time is if God hates you (aka PSU catches on fire) or you are stupid and you go against Tom's recommendation to mix and match different drives.
...or sh*t happens and you are out of luck. What about silent corruption aka bit rot? How does unRAID recover files where bit rot has caused the file to become corrupt and no longer read?
poofyhairguy Wrote:As a bonus Unraid lets you upgrade the array size, one drive at a time, without losing data. With ZFS/RAID you are having to basically build a new array to change hard drive sizes (and then buy all those bigger HDs all at once).
With ZFS you can replace drives with higher capacity one at a time, over whatever time period you choose. When you replace the final drive in the vdev, the extra capacity will be available.
poofyhairguy Wrote:ZFS is a business solution. Unraid is a home media server solution.
ZFS is also used by many *home* users who have discovered its many benefits over other file systems in terms of its data protection features.
To think that people would actually pay for something with lesser data protection features than something that is better and free just makes me scratch my head.
The amount of misinformation people have about ZFS in this thread is quite remarkable, but not that surprising I suppose.
For any open-minded people who wish to learn the superior features within ZFS, take a look here:
- poofyhairguy - 2010-10-13 00:19
Quote:I can't say for all RAID systems, but with ZFS you can choose your preferred level of redundancy. For example, if you're happy with the capacity of one disk for parity data then you could choose a simple 2-drive mirror, or RAID-Z1. If you want more safety then you can choose double-parity like RAID-Z2. If you want triple-parity then you can choose RAID-Z3, which allows three drives to fail before you lose any data.
But is there ANY WAY to configure ZFS to NOT stripe the data in the array so individual drives can be pulled out and read?
Quote:You can mix drives from different manufacturers if you want to with ZFS.
Of different sizes? I thought they all had to be the same size?
Basically what I am saying is that Unraid lets you have an array with different sized drives (and use all the space on those different sized drives). If ZFS CAN use different sized drives and use all the space on those drives please correct me. My understanding is that a ZFS array cannot grow like Unraid or RAID 5 can.
Quote:What about silent corruption aka bit rot? How does unRAID recover files where bit rot has caused the file to become corrupt and no longer read?
Not really a problem with a media server. A HUGE problem with a server that is acting as a business database. That is why I would never put Unraid in my office.
Quote:With ZFS you can replace drives with higher capacity one at a time, over whatever time period you choose. When you replace the final drive in the vdev, the extra capacity will be available.
So basically you are saying "Sure you can replace smaller drives with larger ones, but you won't be able to use that extra space until ALL the small drives are replaced." Is that what you are saying?
Because quite frankly for home use that sucks, and is reason alone to pay for Unraid or WHS for many people.
Quote:To think that people would actually pay for something with lesser data protection features than something that is better and free just makes me scratch my head.
What makes me scratch my head is the fact that so many people push an enterprise system for home use.
For media use what matters most:
-Data is reasonably secure so you don't have to rerip all your DVDs
-To be able to add whatever drive is cheapest on the market at the time you need more space to the array and use all the space on the drive no matter what you originally had in the array
-To be able to saturate a cheap gigabit network with large and constant reads from the server
-To be able to have single folders that span multiple drives
Unraid gives all that, and pretty much nothing more. ZFS can't do all that (unless you CAN use different sized drives in a single ZFS array and use all the space), but adds in a bunch of things that media users don't need.
- darkscout - 2010-10-13 01:35
If you have the $$ you can also put your ZIL onto SSD drives or use them as swap. Or add one as a hot spare (which it will automatically fail over onto).
Hell right now I took all my mismatched IDE drives I have left. Tossed them into a case. Made it RaidZ1 and it's an alternative server.
ZFS really blurs the line between 'device', 'partition', etc. You just add devices to a vdev which is added to a pool.
So my "home" pool could be 2, mirrored vdevs made up of 6 drives in Raidz2. Meaning 2 drives from EACH separate set of drives to fail before I lost things.
And you could always just build a backblaze for $1000 and start adding drives as you go.
- TugboatBill - 2010-10-13 02:29
So if my XBMC client want a movie from a ZFS system does it spin up all the drives or just the one the movie is on?
I have a share "Movies" on a ZFS system. I rip to it and eventually I fill it up. Can I just add another drive to it (of a larger capacity)? Is it just a simple prep the drive (format) and tell ZFS that it's available to the Movies share?
- darkscout - 2010-10-13 02:49
No, ALL the space isn't available. But if ALL the space is available then unRAID isn't backing things up. Meaning if you lose the drive, you lose data.
- TugboatBill - 2010-10-13 02:55
darkscout Wrote:No, ALL the space isn't available. But if ALL the space is available then unRAID isn't backing things up. Meaning if you lose the drive, you lose data.
? I'm sorry, is that a response to my query?
- fonzie - 2010-10-13 03:16
jeez, this is much more information than I was expecting.
I think I'm more confused now than before I posted. haha.
- darkscout - 2010-10-13 03:19
But if you fill up all your drives. (meaning your parity drive too), and just toss in another drive. Anything you put on that drive isn't backed up.
You can add another 2 drives and add the 2 drives in mirror to the pool.