Re: Proper way to delete an old RAID1?

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

 



On Tue, Jun 18, 2013 at 11:42 AM, Caspar Smit <c.smit@xxxxxxxxxx> wrote:
> Hi Mark,
>
> Stopping an MD device will not remove/delete anything.
> The --remove command cannot be used AFTER an MD device is stopped.
> (--remove is only for removing drives/partitions from a running MD
> device NOT to remove the MD itself e.g. mdadm --remove /dev/mdX
> /dev/sdb, furthermore a drive/partition can only be removed after you
> fail the drive first or it has failed by itself offcouse, see the
> --fail switch)
>
> To completely erase the MD you need to stop it and then remove the
> superblocks from the member drives:
>
> mdadm --stop /dev/md127
> mdadm --zero-superblock /dev/sdb5
> mdadm --zero-superblock /dev/sdc5
> mdadm --zero-superblock /dev/sdd5
>
> You can combine the last 3 commands to:
>
> mdadm --zero-superblock /dev/sd[b-d]5
>
> but to be 100% safe use them seperately.
>
> This will erase the superblocks on the members of /dev/md127 and you
> will not be able to assemble it again and it will not be started
> during a reboot (remove it from the mdadm.conf too offcourse, but
> since the array comes up as /dev/md127 I presume it is already not
> present in mdadm.conf)
>
> Kind regards,
> Caspar
>

Thanks Caspar. What you are saying makes more sense to me and is, as
best I can tell, consistent with man mdadm.

I've used this site a few times as it seems to come up a lot when
Googling mdadm questions:

http://www.ducea.com/2009/03/08/mdadm-cheat-sheet/

Apparently his instructions in #3 are incorrect.

Cheers,
Mark

> 2013/6/18 Mark Knecht <markknecht@xxxxxxxxx>:
<SNIP>
>>
>> mdadm --stop /dev/md127
>> mdadm --remove /dev/md127
>>
>> to remove the raid1?
<SNIP>
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[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