Raid 1 disk failed, cannot make active single spare that was rebuilding
by luis.alexandre from LinuxQuestions.org on (#4ZEDK)
I had a 2 disk raid 1. While one of the disks was syncing, the other failed! The failed disk cannot be used, it is really dead (any attempt to access it blocks for 2 minutes and nothing can be read). I have send it back to the store for replacement as it is in the warranty period.
So I am left with only 1 working disk, but it was marked as spare. I cannot start the raid...
I would like to mark this disk as active (not spare) and start the raid with this single disk to be able to copy all data.
How can I do that?
I have tried to stop the raid and force start with the single disk:
Code:sudo mdadm --stop /dev/md128
mdadm: stopped /dev/md128
sudo mdadm --assemble --force /dev/md128 /dev/sda1
mdadm: /dev/md128 assembled from 0 drives and 1 rebuilding - not enough to start the array.Here is some info:
Code:cat /proc/mdstat
Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
md128 : inactive sda1[2](S)
4883637248 blocks super 1.2
unused devices: <none>
sudo mdadm -D /dev/md128
/dev/md128:
Version : 1.2
Raid Level : raid0
Total Devices : 1
Persistence : Superblock is persistent
State : inactive
Working Devices : 1
Name : clevo2:128
UUID : 3318ae78:679f7afc:57f6521a:11cd3fef
Events : 64101
Number Major Minor RaidDevice
- 8 1 - /dev/sda1
sudo mdadm --examine /dev/sda
/dev/sda:
MBR Magic : aa55
Partition[0] : 4294967295 sectors at 1 (type ee)
sudo mdadm --examine /dev/sda1
/dev/sda1:
Magic : a92b4efc
Version : 1.2
Feature Map : 0x3
Array UUID : 3318ae78:679f7afc:57f6521a:11cd3fef
Name : clevo2:128
Creation Time : Fri Jul 19 20:05:09 2019
Raid Level : raid1
Raid Devices : 2
Avail Dev Size : 9767274496 (4657.40 GiB 5000.84 GB)
Array Size : 4883637248 (4657.40 GiB 5000.84 GB)
Data Offset : 264192 sectors
Super Offset : 8 sectors
Recovery Offset : 5598464 sectors
Unused Space : before=264112 sectors, after=0 sectors
State : clean
Device UUID : 0af4c6d9:269b1e71:5d612699:048a258f
Internal Bitmap : 8 sectors from superblock
Update Time : Wed Feb 12 19:41:12 2020
Bad Block Log : 512 entries available at offset 32 sectors
Checksum : 8aea8502 - correct
Events : 64101
Device Role : Active device 1
Array State : AA ('A' == active, '.' == missing, 'R' == replacing)


So I am left with only 1 working disk, but it was marked as spare. I cannot start the raid...
I would like to mark this disk as active (not spare) and start the raid with this single disk to be able to copy all data.
How can I do that?
I have tried to stop the raid and force start with the single disk:
Code:sudo mdadm --stop /dev/md128
mdadm: stopped /dev/md128
sudo mdadm --assemble --force /dev/md128 /dev/sda1
mdadm: /dev/md128 assembled from 0 drives and 1 rebuilding - not enough to start the array.Here is some info:
Code:cat /proc/mdstat
Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
md128 : inactive sda1[2](S)
4883637248 blocks super 1.2
unused devices: <none>
sudo mdadm -D /dev/md128
/dev/md128:
Version : 1.2
Raid Level : raid0
Total Devices : 1
Persistence : Superblock is persistent
State : inactive
Working Devices : 1
Name : clevo2:128
UUID : 3318ae78:679f7afc:57f6521a:11cd3fef
Events : 64101
Number Major Minor RaidDevice
- 8 1 - /dev/sda1
sudo mdadm --examine /dev/sda
/dev/sda:
MBR Magic : aa55
Partition[0] : 4294967295 sectors at 1 (type ee)
sudo mdadm --examine /dev/sda1
/dev/sda1:
Magic : a92b4efc
Version : 1.2
Feature Map : 0x3
Array UUID : 3318ae78:679f7afc:57f6521a:11cd3fef
Name : clevo2:128
Creation Time : Fri Jul 19 20:05:09 2019
Raid Level : raid1
Raid Devices : 2
Avail Dev Size : 9767274496 (4657.40 GiB 5000.84 GB)
Array Size : 4883637248 (4657.40 GiB 5000.84 GB)
Data Offset : 264192 sectors
Super Offset : 8 sectors
Recovery Offset : 5598464 sectors
Unused Space : before=264112 sectors, after=0 sectors
State : clean
Device UUID : 0af4c6d9:269b1e71:5d612699:048a258f
Internal Bitmap : 8 sectors from superblock
Update Time : Wed Feb 12 19:41:12 2020
Bad Block Log : 512 entries available at offset 32 sectors
Checksum : 8aea8502 - correct
Events : 64101
Device Role : Active device 1
Array State : AA ('A' == active, '.' == missing, 'R' == replacing)