Home > Open Source Free Software- > RAID 1 software. When the array is in crisis ...

RAID 1 software. When the array is in crisis ...

This morning, just arrived in my office, I read my mail server sends the account of administration and with great surprise I learned that one of the hard drives configured in RAID 1 (mirroring) has abandoned me. The peculiarity of the error is "degradation" of all configured RAID 1 array. When an event happens like this, where they degrade the array of an entire hard disk, it is highly likely that the disc is ruined and has to be replaced. But here is what error I was notified by e-mail, and as I proceeded to remedy.

On the email I received two messages containing this object:
"DegradedArray event on / dev / md1: server-studio.miodominio";
"DegradedArray event on / dev / md2: server-studio.miodominio";

Given that there are only two on my server RAID array (md1 and md2), dealing respectively with the / boot partition and the /, and given that both arrays were degraded to the fuoriscita by mirroring the partitions residing on the second hard drive, it is highly likely that the latter is a terminally ill patient. Running the command "cat / proc / mdstat", in fact, were not present partitions hdc (the second hard drive).

When this happens it is essential to proceed first with a nice full backup of the data. And 'what I did, moving my few giga up on some DVD and on a third hard drive. Then I attempted to repair the array in this way ...

With the command "fdisk-l" I checked what were the two hard drive partitions to call into the mirror and found this:

Disk / dev / hda: 250.0 GB, 250059350016 bytes
255 heads, 63 sectors / track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/ Dev / hda1 * 1 13 104391 fd Linux raid auto-sensing
/ Dev / hda2 14 30401 244091610 fd Linux raid auto-sensing
Disk / dev / hdc: 250.0 GB, 250059350016 bytes
255 heads, 63 sectors / track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/ Dev / hdc1 * 1 13 104391 fd Linux raid auto-sensing
/ Dev / hdc2 14 30401 244091610 fd Linux raid auto-sensing

As you can see, paying attention to the parts shown in bold, hda1 and hdc1 must be part of the same array (identical sizes of the partitions); hda2 and hdc2 must be part of the same array.

I continued, then, using the command mdadm in this way:

-add # Mdadm / dev / md1 / dev / hdc1

Then I ran the command:

-add # Mdadm / dev / md2 / dev / hdc2

Currently RAID is in the reconstruction:

# Cat / proc / mdstat
Personalities: [raid1]
md2: active raid1 hdc2 [2] hda2 [0]
244091520 blocks [2/1] [U_]
[=====> ...............] Recovery = 29.2% (71281408/244091520) finish = 97.6min speed = 29493K / sec
md1: active raid1 hdc1 [1] hda1 [0]
104320 blocks [2/2] [UU]

It can be seen that the raid array md1 has been rebuilt, while the md2 array is being rebuilt.
The next step will be to see if the secondary hard drive (hdc) is suffering from some hardware problem. To do this, the software will use smartctl :)

  1. December 26, 2008 at 12:05 | # 1

    RAID 1 software. When the array is in crisis ......

    This morning, just arrived in my office, I read my mail server sends the account of administration and with great surprise I learned that one of the hard drives configured in RAID 1 (mirroring) has abandoned me. The special d ...

  1. May 30, 2008 at 15:41 | # 1
  2. May 30, 2008 at 15:41 | # 2
  3. May 30, 2008 at 15:47 | # 3
  4. December 26, 2008 at 12:03 | # 4