View Full Version : Moving Linux software RAID 5 array
PorkCharSui
02-26-2006, 04:52 PM
I'm trying to build a new Ubuntu based media center / server with 4 x 200gb IDE hard drives I picked up on sale, but I had a few questions before I start.
If there are problems with the motherboard in the future, how hard is it rebuild a software RAID 5 array on a new machine?
I'm planning on using EVMS, any tips / suggestions?
Thanks!
unhappy_mage
02-26-2006, 06:45 PM
If you move the array (on a different controller or the same one!) to a different motherboard it'll show up in the same way. It's pretty cool to watch it. I've tried this, it works fine.
I'm planning on using EVMS, any tips / suggestions?
Stick with evms! It is possibly my favorite piece of software for dealing with disks. Let it deal with everything and you will profit.
Your setup is very similar to mine (3x300, sata, and Debian instead) so if you hit problems of any kind post back and I'll help you out.
http://www.hardfolding.com/ftag1.php/mem/150072.png (http://www.hardfolding.com?go=38&tm=33&id=150072)http://www.hardfolding.com/utag.php/mem/1392.png (http://www.hardfolding.com?go=36&id=1392)
PorkCharSui
02-27-2006, 03:43 AM
Great! Now I'm not so scared that I'm going to completely loose my data in a mobo failure.
Now on the topic of stripe size, what size would you recommend for mostly video / audio files?
unhappy_mage
02-27-2006, 10:04 AM
I dunno. I'm using 32k because that's the default. It works just fine. Play around with it if you're concerned. The traditional theory is bigger for larger files, and smaller for smaller files. I'd tend more toward "match the filesystem blocksize" if you're on ext[23], but try different values and see what works.
I'd strongly recommend XFS as the filesystem. It pwns. I corrupted the filesystem to the point that fsck wouldn't recognize it as an xfs filesystem (I had a bad driver for my sata card) and before trying to restore from backup I ran xfs_repair. Half an hour later, I had 95% of my data back online. That beats the heck out of any other filesystem I've used, corrupted, and tried to fix.
http://www.hardfolding.com/ftag1.php/mem/150072.png (http://www.hardfolding.com?go=38&tm=33&id=150072)http://www.hardfolding.com/utag.php/mem/1392.png (http://www.hardfolding.com?go=36&id=1392)
PorkCharSui
03-01-2006, 04:37 AM
Ran into my first problem... using EMVS for the life of me I cannot figure out how to link the drives together to create a single RAID 5 partition. The user guide to EVMS doesn't provide any sort of step by step, and the only stuff I can dig up on Google is all mdadm stuff.
Could you walk me through the basics, or at least point me to a helpful tutorial about setting up EVMS with RAID... or am I suppose to follow the mdadm based guide (http://tldp.org/HOWTO/Software-RAID-HOWTO.html) then setup filesystem through EVMS?
I appreciate your help so much!!
unhappy_mage
03-01-2006, 01:57 PM
Okay, I remembered having a little trouble doing this, but now I shall reveal the secrets. What you need to end up with is drives with partitions on them (fdisk them, add a single disk-sized partition of type 42) but no /dev/evms/sd[a-h]1 links. So when EVMS sees the drives, it assumes you're going to use them as single disks, and creates /dev/evms/sdb1. Go into the EVMS management tool of your choice, and under "Volumes" delete all these links. Make sure not to delete the root volume, though.
Once that's done, go to Actions->Create->Region, select MD4/5 manager, next, select all the disks, next, change options if you want, and finish. A new tab will appear (in evms-gui) or a new thingy in evmsn (hit 3 to get there). Open the options for it (right-click, or enter for evmsn) and select create evms volume. Now it should appear under Logical Volumes. Go there, create a filesystem on it of your choice (but again, xfs is suggested :D). Quit (and do save!) and make an entry in /etc/fstab for the new volume. Note that you'll have to use the evms name for the volume - /dev/evms/raid_vol - as opposed to the md name, probably /dev/md0.
HTH :D
http://www.hardfolding.com/ftag1.php/mem/150072.png (http://www.hardfolding.com?go=38&tm=33&id=150072)http://www.hardfolding.com/utag.php/mem/1392.png (http://www.hardfolding.com?go=36&id=1392)
PorkCharSui
03-02-2006, 12:44 PM
Worked perfectly. The key thing was deleting all the links under volume, allowing them to appear under the create region tool. Setup a little 400gb RAID 5 (3x 200gb). I have to find a PCI IDE controller so I can plug in all 4 drives. I'll be moving the root hard drive / dvd drive to the controller, allowing the raid'd drives to stay connected to the motherboard. (Oh yeah XFS formatting as suggested).
I think you solved /answered everything I had. Thanks again!
unhappy_mage
03-02-2006, 12:47 PM
Unfortunately, you can't add drives to a LSR volume, so you'll have to delete and recreate it. Don't start moving stuff onto it quite yet, IOW :p
http://www.hardfolding.com/ftag1.php/mem/150072.png (http://www.hardfolding.com?go=38&tm=33&id=150072)http://www.hardfolding.com/utag.php/mem/1392.png (http://www.hardfolding.com?go=36&id=1392)
vBulletin® v3.8.2, Copyright ©2000-2009, Jelsoft Enterprises Ltd.