Solved

Recover from dead hard drive (RAID 1)

Posted on 2009-05-20
6
611 Views
Last Modified: 2013-11-08
Hi,

I have a server running four hard drives:
System RAID 1: 2 x 20GB IDE
Storage RAID 1: 2 X 500GB SATA

I am in the process of creating a disaster recovery plan. Say if one of the 20GB drives were to fail I would like to have some instructions on how to configure a new drive to replace the dead drive.

System configuration:

OS: Centos 5
CPU AMD Athlon 3500+
RAM 1.0GB
HDD hard drives running software raid configuration
2 x 20GB IDE system
2 x 500GB SATA storage

Pablo.
0
Comment
Question by:pabgm
  • 2
  • 2
6 Comments
 
LVL 39

Expert Comment

by:PUNKY
ID: 24437361
Turn off the system.
Replace the failed hard drives with new hard drives that are of equal or greater capacity.
If the raid is already set recovery automatically, the recovery process will start automatically when turn on the system.
If the raid recovery is not set up yet, when prompted during system startup, press Ctrl and i (or whatever your raid card) at the same time to enter the raid configuration, check there see if recovery option is set.
 
0
 

Author Comment

by:pabgm
ID: 24439429
Hi,

This is software raid configured by the OS. There is no hardware raid.

Pablo.

0
 
LVL 4

Accepted Solution

by:
colinvann earned 500 total points
ID: 24483861
After you have replaced the physical drive and have booted the system you will be running in a degraded RAID state.

You can check this by running the following command:
  cat /proc/mdstat

Before adding the new disk into the array you would need to create a partition on the new drive of type 'Linux RAID auto' (assuming the new disk is /dev/hda)
  fdisk /dev/hda
  n - new partition
  p - primary partition
  1 - partition 1
  t - change type of partition
  fd - Linux RAID (software RAID)
  w - write the partition table to disk
  q - quit

Now that you have a partition you can add it to the array and it will start rebuilding (assuming /dev/md0 is the RAID device):
  mdadm --manage /dev/md0 -a /dev/hda1

you can check the progress of replication of data to the new disk by watching the contents of the /proc/mdstat file:
  watch "cat /proc/mdstat"

Note: If you do not have mdadm installed you can install it as follows:
  yum install mdadm

Hope that helped.
Colin
0
 

Author Comment

by:pabgm
ID: 24599185
So lets say I remove a disk, my system should still boot?
0
 
LVL 4

Expert Comment

by:colinvann
ID: 24619039
Correct.

If your initial ram disk has the drivers for software RAID (which it must do already because the system is currently booting off a software RAID1 partition) you should be fine.
0

Featured Post

Backup Solution for AWS

Read about how CloudBerry Backup fully integrates your backups with Amazon S3 and Amazon Glacier to provide military-grade encryption and dramatically cut storage costs on any platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In this article you will get to know about pros and cons of storage drives HDD, SSD and SSHD.
We look at whether swapping a controller board on a failed hard drive is likely to solve the problem.
To efficiently enable the rotation of USB drives for backups, storage pools need to be created. This way no matter which USB drive is installed, the backups will successfully write without any administrative intervention. Multiple USB devices need t…
This tutorial will show how to configure a single USB drive with a separate folder for each day of the week. This will allow each of the backups to be kept separate preventing the previous day’s backup from being overwritten. The USB drive must be s…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question