RAID revisited - RE: [lug] RAID installation on Fedora 6 Zod

fred.robinson at sipfusion.com fred.robinson at sipfusion.com
Sat Jun 16 14:57:50 MDT 2007


Ok, so after many Linux installs and characterizations/tests of RAID
installations I've come back to the LUG well to revive this thread - a
thread that I must say provoked a wonderfully spirited discussion!!! 
>From which I drew heavily - Thanks to all who originally posted!

What I'm faced with now, a request for further comments, my secondary
objective for RAID/high availability;
     - So my scenario goes; RAID-1 is installed, mdadm mirroring works
flawlessly.  However, now I want to be able to mdadm fail/remove the
2nd mirrored disk, leaving it in the box as a "Psedo-Hot-Standby" disk,
and 'mdadm add' it back in from time to time to sync it with the primary
disk.  My needs are for a dual purpose solution that provides both a
disk failure/data loss and a data corruption and recovery contingency.
     - Supposing my primary Fedora 6 Zod installation becomes corrupted
but still boots and begins to run in a compromised/crippled condition;
          - MY QUESTION, finally;
                - Is there a way, via mdadm RAID-1 to swap the primary
RAID-1 drive with the secondary drive and cause a sync from the "hot
standby" disk to the primary disk, effectively undoing whatever
corruption occurred on the primary disk (in my case primary disk, hde,
secondary disk, hdg) - without physically swapping IDE cables from the
alternate-primary sockets on the IDE controller card (or conversely,
even less sophisticated, physically unplugging the primary IDE
disk/cable/or power and rebooting)?

More Details about my configuration...........

Ok, my original thought, per comments on LUG thread, was to keep my RAID
simple and use Hardware RAID only, allowing the hardware RAID controller
BIOS to handle the RAID.  I purchased a couple inexpensive Silicon Image
SIL680-RAID PCI Cards.  Ok, ok, ok, I know now that one cannot expect
much from "cheapo" RAID cards.  If you've worked with these cards you
know the word on the web is that they're crap, however, the product
description failed to adequately describe the onboard chipset so I
wasn't able to do proper advance research before buying.  Since they
were only $12ea. I concluded it was really only time I would lose if
they didn't work and whatever learning occurred the experience would
invaluable.

After 3 or 4 Fedora installs and numerous 'googles' for explanations I
learned that these cards are not true hardware RAID and require
software augmentation to do effective RAID.  During my research, of
course, there was much to be said for Linux Software RAID and I must
remark that the large majority of discussion was positive and described
a quite simple software RAID setup.  So I adjusted my approach and
decided to ditch the Hardware RAID approach and go with software.

I followed the method described here to setup my RAID disks during
Fedora installation;
http://www.texsoft.it/index.php?c=hardware&m=hw.storage.grubraid1&l=it

Immediately I discovered that Fedora installation wouldn't detect my
second disk during the install if it were on the same IDE ribbon cable,
with disk jumpers setup as neither slave nor primary (this was puzzling,
but a discussion for another time).  At this point I needed another IDE
socket to get the installer to recognize the second disk.  Since my M/B
only has 2 IDE sockets on board, one for CD-ROM, needed for Fedora
install CD's, and one for hdd, I needed another native IDE socket.  I
decided to try to use the SIL680-RAID card as a simple IDE controller
card, no RAID configured in the card BIOS.  The installer indeed
recognized both disks, so I continued with RAID setup per the URL
above.

This URL describes, as many other URL's I found also describe, setting
up mdadm "md0" and "md1" partitions during the install (NOTE: I did
attempt to setup these partitions with my last good install, but
recieved errors, not quoting, that basically said md0 create operation
could not be completed since hdc is busy - perhaps another discussion
to be had; how to install mdx RAID partitions on an existing set of
running partitions).  My disks connected to the SIL680-RAID card were
identified as hde, primary, and hdg, secondary master.  The method
worked seamlessly, installation completed without a hitch, and "cat
/proc/mdstat" shows mirroring is working.  To test I shutdown,
unplugged hde, booted and hdg boots and runs perfectly.  I then add
hde1 and hde2 back into md0 and md1 RAID, respectively, disks re-sync,
followed by reboot, works perfectly.

Coming full circle, back to my question at the top; ........is there a
way, using madadm, to cause the "dropped-removed" disk to become the
master, upon re-adding to the RAID, that would over-write the
running/corrupted disk?

Regards,
Fred Robinson
Operator, SIPFusion, LLC.
 




> -------- Original Message --------
> Subject: Re: [lug] RAID installation on Fedora 6 Zod
> From: User Dan Ferris <dan at usrsbin.com>
> Date: Mon, May 21, 2007 10:13 am
> To: "Boulder (Colorado) Linux Users Group -- General Mailing List"
> <lug at lug.boulder.co.us>
> 
> You can do gmirror at the OS install or after.  It matters not.  The 
> FreeBSD installer gives no way to use it.  I usually do it after booting 
> into FreeBSD the first time.  It's about a 2 minute process.
> 
> On Mon, 21 May 2007, Sean Reifschneider wrote:
> 
> > On Wed, May 16, 2007 at 02:40:52PM -0600, User Dan Ferris wrote:
> >> I was saying Linux software RAID is harder compared to Solaris
> software
> >> RAID and FreeBSD's software RAID because it's much harder to set it up
> >> after the OS is installed.  With metainit and gmirror you can
> create arrays
> >> without dealing with copying things from disk to disk.
> >
> > The first hit on google for "gmirror" says:
> >
> >   It made more sense to me to configure RAID during the install of the
> >   operating system.
> >
> > The man page for gmirror says that it uses on-disc meta-data, so you
> can't
> > just lay it down on an existing file-system unless there's room for the
> > meta-data there already.  Which makes it sound like you'd run into
> the same
> > problems as with Linux software RAID, which also uses on-disc
> meta-data.
> > Of course, in Linux you can also build arrays without using the on-disc
> > meta-data, meaning that you can mirror a partition without modifying
> it at
> > all...  However, I wouldn't recommend it.
> >
> > Getting back to the original poster, I'm assuming that if you are
> asking on
> > a mailing list about doing it on a recently installed machine that
> "let the
> > installer take care of it" is an answer that is likely to meet their
> needs.
> > I don't have time to document how you would go about doing this, but
> I do
> > have time to suggest this, possibly overlooked, option.
> >
> > Sean
> > -- 
> > "You took quite a chance..."  "You take a chance getting up in the
> morning,
> > crossing the street, or sticking your face in a fan."  -- Police Squad
> > Sean Reifschneider, Member of Technical Staff <jafo at tummy.com>
> > tummy.com, ltd. - Linux Consulting since 1995: Ask me about High
> Availability
> >
> > _______________________________________________
> > Web Page:  http://lug.boulder.co.us
> > Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> > Join us on IRC: lug.boulder.co.us port=6667 channel=#colug
> >
> >
> >
> _______________________________________________
> Web Page:  http://lug.boulder.co.us
> Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> Join us on IRC: lug.boulder.co.us port=6667 channel=#colug




More information about the LUG mailing list