Re: Raid 5 cannot be re-assembled after disk was removed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> A three disk raid5 with spare (odd, why not raid6 then?)
Because the 4th disk was not in the initial setup and i never moved
from raid5 to raid6.

> or whatever reason, it's a 4 disk raid5 now.
This is because i activated the spare disk so it could sync but after
sync finished i failed and removed the defective disk but somehow the
raid was not rebuilding.
The array was not mounted since the 4th (previously spare) was added.

> You can't assemble a 4 disk raid5 with only 2 drives.
I would like to make the 4 disk raid5 to a 3 disk raid5 and assemble
this one with 3 drives.
Can't i assemble the array with the (hopefully) fine 2 disks first
(without redudancy) and then add the 3rd disk to build up redudancy
and resync to it?
Or recreate with --assume-clean with 3 disks?
I could also try to reconnect the defective disk - it is still working
but has some read errors - and add it back to the array if this helps.

Thanks

Am Mi., 8. Jan. 2020 um 11:03 Uhr schrieb Andreas Klauer
<Andreas.Klauer@xxxxxxxxxxxxxx>:
>
> On Wed, Jan 08, 2020 at 10:31:28AM +0100, Marco Heiming wrote:
> > So here is what what it looked like at the time it was working:
> >
> > mdadm -D /dev/md0
> > /dev/md0:
> >   Creation Time : Wed Jan  7 18:14:37 2015
> >      Raid Level : raid5
> >      Array Size : 5860270080 (5588.79 GiB 6000.92 GB)
> >   Used Dev Size : 2930135040 (2794.39 GiB 3000.46 GB)
> >    Raid Devices : 3
> >   Total Devices : 4
>
> A three disk raid5 with spare (odd, why not raid6 then?)
>
> > Somehow the spare was not activated and so the array degraded was inactive.
> >
> > I activated the spare and the array was syncing.
>
> Then something went wrong in this step.
> It seems like you did something else.
>
> > mdadm --examine /dev/sd[b-z]
> > /dev/sdb:
> >   Creation Time : Wed Jan  7 18:14:37 2015
> >      Raid Level : raid5
> >    Raid Devices : 4
> >
> >  Avail Dev Size : 5860274096 (2794.40 GiB 3000.46 GB)
> >      Array Size : 8790405120 (8383.18 GiB 9001.37 GB)
> >   Used Dev Size : 5860270080 (2794.39 GiB 3000.46 GB)
>
> For whatever reason, it's a 4 disk raid5 now.
>
> Array size went up from 6000GB to 9000GB accordingly.
>
> >    Device Role : Active device 1
> >    Array State : AAA. ('A' == active, '.' == missing, 'R' == replacing)
>
> And one disk is missing so no redundancy here.
>
> > When i try to assemble the array with the two (hopefully) fine drives it fails:
>
> You can't assemble a 4 disk raid5 with only 2 drives.
>
> Your examine also only gave two disks out of 4.
>
> You need 3 drives with good data on them, and a 4th drive to restore redundancy.
> Whether you have those 3 drives, only you yourself know...
>
> Regards
> Andreas Klauer



[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux