Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
hda = DVD ROM
hdb = NEW 40gb PATA IDE O/S drive (centos)
sda = OLD 80gb SATA IDE Mandriva 2006 O/S (Corrupted)
hdc = RAID1 array disk 0
hde = RAID1 array disk 1
Did a trial run on a test setup of the same arrangement making notes and all went fine.
During the "real thing" though the Centos installer detected that one disk in the RAID1 array (hdc) had a corrup partiton table and so had to be re-initalised. hdc was re-initalised and configured as 'Software raid' but I did not created a raid device (md0) at that point.
I have made a note of which disk was detected correctly without error as a 'software raid' format disk still containing data (hde) and ensured that data on this disk is to be preserved and not formatted.
Is there a prcedure that post install will allow me to recreate RAID disk md0 but specify which is the master in the set (hde) and rebuild the other from that ?
I have a tape backup of the data which was taken a few days earlier, so should all go to pot I can start again with that. It would be nice not to have to resort to that though !
There is no master in a RAID1 array. Whichever disk is currently in the array will be the source for whichever disk is added. The procedure is here.
Hi Mace,
Thanks for taking the time to respond to my post. Have looked at the link however that seams to be more when an array has failed insitu rather than my setup (or at least to my untrained eye!)
Is there a way I can define a raid1 setup with and say rebuild using hde as the source ? (perhaps with hdc initally removed ?)
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,500
Rep:
You can assemble the array with one drive missing. For example:
mdadm -A /dev/md0 /dev/hde1
The array will be assembled with just the one drive. You can fsck it, mount it, whatever you need to check it out. You can then add the second drive to start the mirror resync:
You can assemble the array with one drive missing. For example:
mdadm -A /dev/md0 /dev/hde1
The array will be assembled with just the one drive. You can fsck it, mount it, whatever you need to check it out. You can then add the second drive to start the mirror resync:
mdadm /dev/md0 --add /dev/hdc1
Brilliant!
Sorry to appear thick, but how do I make sure it know's it's a RAID1 setup ?
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,500
Rep:
The superblock on the drive and/or the /etc/mdadm.conf (or /etc/mdadm/mdadm.conf) will be used by the mdadm command to determine the parameters. You can check the drive superblock before starting with (for example):
mdadm --examine /dev/hde1
Once the array has been assembled (even in degraded mode) you can:
cat /proc/mdstat
To see what the system understands the configuration to be. For example:
The superblock on the drive and/or the /etc/mdadm.conf (or /etc/mdadm/mdadm.conf) will be used by the mdadm command to determine the parameters. You can check the drive superblock before starting with (for example):
mdadm --examine /dev/hde1
Once the array has been assembled (even in degraded mode) you can:
cat /proc/mdstat
To see what the system understands the configuration to be. For example:
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.