Re: Converting a regular (non-RAID) HD into a (degraded) RAID 1 installation in-place

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

 



On Tue, 9 Apr 2013, Rogério Brito wrote:

I would like to understand better this situation and I can provide all the details (commands) that I tried so far.

My recommendation would be to choose a metadatatype that stores the metadata at the end of the partition, and before this you shrink your ext4 fs by 100 megabyte or alike, and then after you see this correctly through the md device, you resize it again to "max".

You didn't state if you needed partitions here, but I would imagine not.

So let's say you have sdb1 with ext4 fs. Shrink fs on sdb1 by 100 megabyte. mdadm --create md0 raid1 on sdb1 with metadata v1.0, then you can most likely mount ext4 properly on md0, and after this you can resize the fs to max size. Now you have md0 on sdb1 and one missing, then you can add sdc1 to this to have a fully functioning raid1 setup.

--
Mikael Abrahamsson    email: swmike@xxxxxxxxx

[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