PDA

View Full Version : NAS Raid 5


litkaj
10-20-2005, 03:21 PM
Right now I've got 3 250GB drives attached to my HTPC via USB2 enclosures. Unfortunately, they just aren't cutting it. My movies occasionally skip (this doesn't occur if I pull one across my network from a different system) and I have zero redundancy.

I'd like to setup a little PATA NAS that supports RAID 5 but I haven't been able to come across anything that doesn't cost $600+ (without drives). I'd like to spend around $300. Are there any black boxes in that range that will support 4 drives for RAID 5?

If not, does anyone have experience with software RAID 5 arrays under Linux? How much CPU power is needed? Can a 1GHz Mini-ITX board saturate a 100Mbit link? Are they machine portable (meaning, if my primary drive craps out, can I move the entire array to a different Linux box and get it back up and running)? Can you expand a software RAID 5 array under Linux (meaning, if I have 3 drives for a total of 500GB usable in my array, can I add a 4th at a later date to make it 750GB usable without having to backup all my data and blow everything out)?

Any info or suggestions would be appreciated because this damn skipping is starting to irritate me...

DougLite
10-20-2005, 03:28 PM
Unhappy_Mage is our resident Linux software RAID wizard, I'm sure he'll fill in the details/corrections on what I'm about to say - if what he says conflicts with what I post here, listen to him :D

I am pretty sure Linux software RAID will meet all of your goals.

vmerc
10-20-2005, 03:35 PM
From what i understand about the RAID 5 standard, you should be able to add drives to the array on the fly. There was a NAS box I saw a review for a while back that was a 4 drive bay with RAID5 support. I'll have to find the link.

litkaj
10-21-2005, 04:30 PM
Any assistance, either with a black box, or with Linux Software RAID, would be appreciated. Thanks guys.

TeedOff
10-21-2005, 07:12 PM
Here's a little RAID 5 box I built a while back:

http://www.teedoffweb.com/pics/mods/teraserver/teraserver-final.JPG

Details of the build:
5x200GB PATA in RAID 5 giving about 760 GB of formatted storage
Morex Venus 688 Cube case
5 in 3 PATA Removable drive cage
VIA EPIA M10000 Nehemiah mainboard
HighPoint RocketRAID 454 4 channel PATA RAID Controller

Performance of WRITE operations with the HighPoint controller is only so-so (seat of the pants...I can bench it if someone can recommend a tool) in RAID 5 due to the fact that the load for the parity calculations falls to the EPIA CPU. Read performance is quite acceptable.

-TeedOff

RavenD
10-21-2005, 07:21 PM
I know offhand software raid under linux IS machine portable - no risks of having a controller card crap out and then being unable to find a card with an identical bios. I expect that it supports online expansion, however I would like for someone who knows more than me on the subject to confirm that.

As for CPU requirements - I'm wondering the same thing. I have a P3 700Mhz@850 (I'm sure it'll go a good deal higher without compromising stability) with a motherboard has 4 PATA channels that I'd like to convert into a file server (provided the board supports large disks), but I dont know whether the CPU could handle it.

NulloModo
10-21-2005, 09:17 PM
Right now I've got 3 250GB drives attached to my HTPC via USB2 enclosures. Unfortunately, they just aren't cutting it. My movies occasionally skip (this doesn't occur if I pull one across my network from a different system) and I have zero redundancy.

I'd like to setup a little PATA NAS that supports RAID 5 but I haven't been able to come across anything that doesn't cost $600+ (without drives). I'd like to spend around $300. Are there any black boxes in that range that will support 4 drives for RAID 5?

If not, does anyone have experience with software RAID 5 arrays under Linux? How much CPU power is needed? Can a 1GHz Mini-ITX board saturate a 100Mbit link? Are they machine portable (meaning, if my primary drive craps out, can I move the entire array to a different Linux box and get it back up and running)? Can you expand a software RAID 5 array under Linux (meaning, if I have 3 drives for a total of 500GB usable in my array, can I add a 4th at a later date to make it 750GB usable without having to backup all my data and blow everything out)?

Any info or suggestions would be appreciated because this damn skipping is starting to irritate me...

You have a multidrive USB2 enclosure? I have been looking for something like that, linky please?

unhappy_mage
10-21-2005, 11:55 PM
If not, does anyone have experience with software RAID 5 arrays under Linux? How much CPU power is needed? Can a 1GHz Mini-ITX board saturate a 100Mbit link? Are they machine portable (meaning, if my primary drive craps out, can I move the entire array to a different Linux box and get it back up and running)? Can you expand a software RAID 5 array under Linux (meaning, if I have 3 drives for a total of 500GB usable in my array, can I add a 4th at a later date to make it 750GB usable without having to backup all my data and blow everything out)?
Yes.
Not much - the more important thing is a well-supported controller and a fast bus if possible.
Probably, but the CPUs on those are lacking compared to for example an Athlon of the same speed. I'd be pretty surprised if it didn't, though.
Yes.
Yes, I think, depending on the raid system. I suggest evms, which is really really powerful. It's overkill for anything I can think of.

http://www.hardfolding.com/ftag1.php/mem/150072 (http://www.hardfolding.com?go=38&id=150072&tm=33)

litkaj
10-24-2005, 01:30 PM
You have a multidrive USB2 enclosure? I have been looking for something like that, linky please?

No, I have several single-drive enclosures filling up all my USB ports.

Yes.
Not much - the more important thing is a well-supported controller and a fast bus if possible.
Probably, but the CPUs on those are lacking compared to for example an Athlon of the same speed. I'd be pretty surprised if it didn't, though.
Yes.
Yes, I think, depending on the raid system. I suggest evms, which is really really powerful. It's overkill for anything I can think of.

I was looking at using OpenFiler but every time I tried to install it to a VMWare box with 3 250GB HDs, it errored out during the install. It may have had something to do with the way I was partitioning the system (3 RAID partitions on each drive, one RAID 1 for "/" using 10GB and EXT3, one RAID 1 for swap using 512MB, and one RAID 5 LVM volume using the remaining ~490GB). I was planning on using it because it has a nice web GUI. To be honest though, I really only need one big-ass share for all my movies and music that I've spent countless hours ripping, sothe web GUI isn't really necessary. I'll check this out and perhaps try a simple CentOS 4.2 box with EVMS on top for drive management. Thanks.

unhappy_mage
10-24-2005, 02:00 PM
Fedora is pretty easy to get going with Samba, and really, once you get it going there's not much need to configure anything. Just set and forget. That's my recommandation for an easy file server box.

http://www.hardfolding.com/ftag1.php/mem/150072 (http://www.hardfolding.com?go=38&id=150072&tm=33)

litkaj
10-25-2005, 10:49 AM
I've used Fedora in the past but since I already have the CentOS 4.2 CDs and DVD on hand from some Asterisk installs at work, I think I'll use them unless I run into trouble.

Speaking of trouble, I'm having some issues already. I've been trying to build a virtual machine in VMWare (v5.5 RC) for testing the expansion capabilities of EVMS, as well as rebuilding after a simulated drive failure, before I actually go out and buy the rest of the hardware I need (Mini-ITX board, RAM) but after the install completes and it reboots I just get a blank screen, grub never loads. I think it may have something to do with my trying to boot from a RAID partition but I was under the impression that you could boot from software RAID 1. My partition scheme is below, anyone know what exactly is going wrong here?

All partitions are of type "Software RAID" and are then mapped as is shown in the next section.

Disk 1:
hda1 - 10237 MB
hda2 - 510 MB
hda3 - 245250 MB

Disk 2:
hdb1 - 10237 MB
hdb2 - 510 MB
hdb3 - 245250 MB

Disk 3:
hdc1 - 10237 MB
hdc2 - 510 MB
hdc3 - 245250 MB


/dev/md0 - hda1, hdb1, hdc1 - RAID1 ext3 (mounted as "/")
/dev/md1 - hda2, hdb2, hdc2 - RAID1 swap
/dev/md2 - hda3, hdb3, hdc3 - RAID5 LVM


Grub is installed on /dev/md0.

DougLite
10-25-2005, 11:07 AM
IIRC, you still need a conventional boot volume, enough to get the ataraid subsystem going. Can your system boot from a memory card reader?

litkaj
10-25-2005, 03:28 PM
Well, as I said, I'm trying to get this running in VMWare first, so not really. The thing I'm trying to avoid here is having a single point of failure in the disk subsystem. If I can RAID1 the "/" partition ("/boot" isn't on a separate partition) then even if a drive fails, I should still be able to boot.

From what I've read, it should be possible to load a / partition which is running RAID 1 if you use a ramdisk to load the appropriate modules. I assumed, incorrectly it seems, that the stock kernel for RHEL4 and CentOS 4.2 would have those modules in the initrd image.

unhappy_mage
10-25-2005, 05:29 PM
There are two ways to boot from a RAID array, but I haven't tried either, so YMMV. The first is to build all the needed modules directly into the kernel and ignore the initrd; the other is to build everything as a module and make an initrd. I always go for the first approach; building an initrd is a pain.

http://www.hardfolding.com/ftag1.php/mem/150072 (http://www.hardfolding.com?go=38&id=150072&tm=33)

rodsfree
10-26-2005, 09:15 AM
I was under the impression that you'd be better off with a single boot drive.
Say a really cheap 10 gigger or so for your boot drive and OS et al.
Then build the RAID array off of that.
Then if the boot drive fails all you have to do is reinstall the os on to another drive and the array will still be intact.

But if you could have a RAID 1 boot I guess it would be safer. 2 X 10 giggers
Then have a RAID 5 stoarge array. 3 X 250GB's

But I'm not a RAID or LINUX expert. Just a dabbler. ;)
Fold-Server is my one linux experience, cept for the live cd's :rolleyes:



http://www.hardfolding.com/ftag1.php/mem/2172.png (http://www.hardfolding.com?go=38&id=2172)

litkaj
10-26-2005, 05:44 PM
Alright then, how exactly do I go about recompiling a kernel under CentOS? Everytime I try to build the kernel it errors out about 5 lines in, even without any changes to the .config file (most of my Linux experience is with Gentoo and I've never had a problem rolling my own there).

Please correct me if I'm wrong, but I should be able to do the install as normal, boot from a LiveCD, chroot into the other environment, and then build a new kernel so I can boot without the LiveCD.

[root@storage 2.6.9-22.EL-i686]# pwd
/usr/src/kernels/2.6.9-22.EL-i686
[root@storage 2.6.9-22.EL-i686]# make
CHK include/linux/version.h
SPLIT include/linux/autoconf.h -> include/config/*
CHK include/asm-i386/asm_offsets.h
make[1]: *** No rule to make target `init/main.o', needed by `init/built-in.o'. Stop.
make: *** [init] Error 2
[root@storage 2.6.9-22.EL-i686]#

unhappy_mage
10-26-2005, 05:46 PM
I'd get a vanilla kernel from kernel.org and try that. Who knows what weird patches are in CentOS's kernel source.

http://www.hardfolding.com/ftag1.php/mem/150072 (http://www.hardfolding.com?go=38&id=150072&tm=33)

litkaj
10-26-2005, 06:11 PM
Oh, what the hell... Apparently CentOS doesn't install the kernel sources by default (but it does give you the .config, go figure).

I just found this:

#rpm -i kernel-2.6.9-11.EL.src.rpm
- Go to the /usr/src/redhat/SOURCES directory and modify the kernel-2.6.9-i686.config file
- Go to the /usr/src/redhat directory and rebuild the kernel RPM as shown below
#rpmbuild -ba --target=i686 SPECS/kernel-2.6.spec


I'll give that a try, along with a vanilla kernel. Thanks.