Doh!

At least you'll have the chance to change that now.. :)

Regards,
Jens Dueholm Christensen

-----Original Message-----
From: [email protected] 
[mailto:[email protected]] On Behalf Of Sturgis, Grant
Sent: 27. oktober 2010 17:42
To: [email protected]
Subject: RE: Software RAID Recovery

Thanks Jens, this is an excellent howto.

In my case, my disks were (unknown to me) configured as RAID level 0, so
I was out of luck.

 

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Jens Dueholm
Christensen
Sent: Wednesday, October 27, 2010 8:55 AM
To: [email protected]
Subject: RE: Software RAID Recovery

I've had the same thing happen to me, and I did the following (this
works for RHEL4u3, which is a bit old, but..):

1) Remove the faulty disk and insert a new one

2) Boot from an installation media where you can go into a rescue mode
(for RHEL you just type "linux rescue" at the boot prompt)

3) Don't start any network

4) Don't search for any partitions

5) Start fdisk and partition your new sdb disk to the same layout as the
existing sda disk
  Note that if you havn't got a record of partitionsizes and layout you
can use fdisk to print the layout and sizes from your disk with data on
it..

6) Verify your new partitionsizes and make sure you're using the new
blank disk and not the one holding data!

7) Assemble and start the mdX partitions, hotadd the same partition from
the new disk and wait for a rebuild
  Assemble the devices like this (there sda is the working disk with
data):
    mdadm -v -A /dev/mdX /sdaX
  Start the new md-device
    mdadm -v -R /dev/mdX
  Hotadd the new partition and rebuild of data starts
    mdadm -a /dev/mdX /dev/sdbX
After rebuild is complete (cat /proc/mdstat for progress) 

8) Reboot

9) Boot to the rescue mode from CD again (and this time scan for
partitions!) and put a bootloader on the new disk (the following
explains how for grub)
  Note that in grub sda is known as hd0 and sdb is know as hd1..
  Start grub and enter the following 3 commands:
    root (hd1,0)
      It should answer with something like this:
      Filesystem type is ext2fs, partition type 0xfd
    setup (hd1)
      This writes a bootloader to sdb
    quit
      We're done - let's get back to the shell

Now reboot, and your system should be back as it was..

Note that partitioning the new disk with fdisk can be tricky, and be
very very careful not to fdisk your disk with data on it.

Also 
Regards,
Jens Dueholm Christensen 

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Sturgis, Grant
Sent: 26. oktober 2010 18:28
To: [email protected]
Subject: Software RAID Recovery

Greetings list,

Unfortunately, I'm in need of RAID recovery.  I can probably wing it,
but I've had problems in the past, and I don't want to blow it, so I'm
asking for some help here.

Two disks, /dev/sda and /dev/sdb, sdb is the one that failed.  The
system can not start the second disk at all, but I do have a replacement
disk.  Also - the system will not boot with the one disk, and I'm
guessing it panicked overnight.

/dev/sda1 is /boot
/dev/sda2 is /usr
/dev/sda3 is /home
/dev/sda4 is Extended
/dev/sda5 is Swap
/dev/sda6 is the RAID partition

I'm in the process of restoring from tape the contents of /etc
(particularly fstab and the mdadm.conf file).  I'm guessing
that /dev/sdb had a single partition that was the same size as /dev/sda6
and the two were married into /dev/md0

If so, any suggestions as to how to proceed are most welcome.

(I am able to boot into CentOS 4.4 rescue mode, as well as boot into a
Live CD).

Thanks for your help.


_______________________________________________
Linux-PowerEdge mailing list
[email protected]
https://lists.us.dell.com/mailman/listinfo/linux-poweredge
Please read the FAQ at http://lists.us.dell.com/faq

_______________________________________________
Linux-PowerEdge mailing list
[email protected]
https://lists.us.dell.com/mailman/listinfo/linux-poweredge
Please read the FAQ at http://lists.us.dell.com/faq

_______________________________________________
Linux-PowerEdge mailing list
[email protected]
https://lists.us.dell.com/mailman/listinfo/linux-poweredge
Please read the FAQ at http://lists.us.dell.com/faq

_______________________________________________
Linux-PowerEdge mailing list
[email protected]
https://lists.us.dell.com/mailman/listinfo/linux-poweredge
Please read the FAQ at http://lists.us.dell.com/faq

Reply via email to