For raid10 -> raid0 takeover operation we shoud reject disks in mirror by mark them as 'failed' and then remove them from array. For external metadata second action should be execuded by mdmon so additional condition is necessary. Signed-off-by: Krzysztof Wojcik <krzysztof.wojcik@xxxxxxxxx> --- Grow.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/Grow.c b/Grow.c index 78d5b0e..c5f83a8 100644 --- a/Grow.c +++ b/Grow.c @@ -711,7 +711,9 @@ int remove_disks_on_raid10_to_raid0_takeover(struct supertype *st, sysfs_set_str(sra, sd, "state", "faulty"); sysfs_set_str(sra, sd, "slot", "none"); - sysfs_set_str(sra, sd, "state", "remove"); + /* for external metadata disks should be removed in mdmon */ + if (!st->ss->external) + sysfs_set_str(sra, sd, "state", "remove"); sd->disk.state |= (1<<MD_DISK_REMOVED); sd->disk.state &= ~(1<<MD_DISK_SYNC); sd->next = sra->devs; -- 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