0

I have had a long-standing raid1 array with two member disks that was degraded when the power connector to one of the raid1 disks was accidentally disconnected while the system was powered off and subsequently rebooted. On boot, the INTEL Rapid Storage Tech bios reported that the disconnected drive was removed from the raid array. The system is running a 5.4 linux kernel. The array was originally created in 2011 with two identical 2Tb western digital disks. The raid array was constructed from whole disks, sda and sdb, each with 3 identical primary and one extended ext partitions. To emphasize, the partitions are ext, not raid identified partitions. The original disk installed as sdb failed years ago and was replaced by a similar sized, but not identical Seagate drive. The raid mirror array was automatically reconstructed when that drive was installed years ago and functioned properly until this problem arose.

Using operating system tools (mdadm, /proc data), sdb is now reportedly removed from the raid array, although physically present and defect free according to a smartools test.

**proc/mdstat shows two raid arrays, although only one is in use:

Personalities : [raid1] [linear] [multipath] [raid0] [raid6] [raid5] [raid4] [raid10] 
md126 : active raid1 sda[0]
      1953511424 blocks super external:/md127/0 [2/1] [U_]
      
md127 : inactive sda[1](S) sdb[0](S)
      6320 blocks super external:imsm
       
unused devices: none

Attempts to re-add sdb back to /dev/md126 fail as follows:

mdadm /dev/md126 --re-add /dev/sdb
mdadm: Cannot add disks to a 'member' array, perform this operation on the parent container

From what I have gathered, the parent container is /dev/md127 or /dev/md/imsm0 (linked to each other), but attempts to re-add the device to the parent container also fail.

mdadm /dev/md127 --re-add /dev/sdb
mdadm: Cannot open /dev/sdb: Device or resource busy

Currently /dev/md126p5 is mounted as /home on the system. According to the system, md126 is contained within md127. How this architecture was established is unclear to me, as is its necessity, which seems unnecessarily complex. My understanding of raid arrays was and is weak and I never intentionally created this structure. As I recall, the array was originally referenced as /dev/md0 prior to the real disk drive failure years ago.

If all else fails, I have a full backup of the data, but it seems to me that this problem should be easily solved with the proper sequence of mdadm commands. The operating system/ functioning boot data are not on this raid array. However, when originally constructed, redundant boot data was placed on partitions /dev/sda1 and /dev/sdb1 (/dev/md126p1) for possible emergency use, but the system boots from /dev/sdc1, not a raid member. Can I stop /dev/md127 which is inactive even though it seems to contain /dev/md126? Do I then mark /dev/sdb as failed then re-add it in /dev/md126?
If I understand correctly, md127 contains inactive "spares" that are physically the same drives as assembled in md126.

Thanks for your help.

1 Answer 1

0

EXECUTIVE SUMMARY: The Intel Option ROM, NOT mdadm, was used to restore the raid1 array.

Ultimately, I was not able to use mdadm to fix this problem. I tried many solutions suggested for raid1 repair found elsewhere. These included stopping all arrays, failing the device which I knew to have been removed from the array, then attempting to re-add it. I also attempted to shrink the raid1 array down to a single disk, hoping I could then grow it by adding the removed disk. Shrinking the array was not possible. After making sure my data backup was complete, I rebooted the system and during the boot process entered the Intel option rom configuration routine. I deleted the removed member disk from the raid1 array. The option rom then prompted me to add a disk back to the array and I selected the drive that I had just deleted from the array. The option rom then indicated that they array rebuild had been started and that it would be continued under operating system control. The rebuild is currently proceeding and the contents of /proc/mdstat are currently as follows:

Personalities : [raid1] [linear] [multipath] [raid0] [raid6] [raid5] [raid4] [raid10]
md126 : active raid1 sda[1] sdb[0]
1953511424 blocks super external:/md127/0 [2/1] [U_]
[====>................]  recovery = 21.2% (415849728/1953511424) finish=271.3min speed=94440K/sec

md127 : inactive sda1 sdb0 6320 blocks super external:imsm

unused devices:

mdadm -Q -D --detail /dev/md126 /dev/md126: Container : /dev/md/imsm0, member 0 Raid Level : raid1 Array Size : 1953511424 (1863.01 GiB 2000.40 GB) Used Dev Size : 1953511424 (1863.01 GiB 2000.40 GB) Raid Devices : 2 Total Devices : 2

         State : active, degraded, recovering 
Active Devices : 1

Working Devices : 2 Failed Devices : 0 Spare Devices : 1

Consistency Policy : resync

Rebuild Status : 21% complete UUID : e45fff5d:bd2a6b2a:ad2ac1da:3192f320 Number Major Minor RaidDevice State 1 8 0 0 active sync /dev/sda 0 8 16 1 spare rebuilding /dev/sdb

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .