The following patch makes it possible to tag a device as write-mostly on
--add and --re-add with a non-persistent superblock array. Previously,
this was not working.
Thanks,
Paul
Signed-Off-By: Paul Clements <paul.clements@xxxxxxxxxxxx>
Manage.c | 2 ++
1 files changed, 2 insertions(+)
--- mdadm-2.4/Manage.c 2006-03-28 01:11:11.000000000 -0500
+++ mdadm-2.4-fix-write-mostly/Manage.c 2006-03-31 21:56:37.000000000 -0500
@@ -341,6 +341,8 @@ int Manage_subdevs(char *devname, int fd
break;
}
}
+ if (dv->writemostly)
+ disc.state |= (1 << MD_DISK_WRITEMOSTLY);
if (ioctl(fd,ADD_NEW_DISK, &disc)) {
fprintf(stderr, Name ": add new device failed for %s as %d: %s\n",
dv->devname, j, strerror(errno));