Skip to content

Commit 5492c46

Browse files
Alexey Obitotskiyshligit
authored andcommitted
md: notify about new spare disk in the container
In case of external metadata arrays spare disks are added to containers first. mdadm keeps monitoring /proc/mdstat output and when spare disk is available, it moves it from the container to the array. The problem is there is no notification of new spare disk in the container and mdadm waits a long time (until timeout) before it takes the action. Signed-off-by: Alexey Obitotskiy <[email protected]> Signed-off-by: Shaohua Li <[email protected]>
1 parent 208410b commit 5492c46

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

drivers/md/md.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4283,6 +4283,8 @@ new_dev_store(struct mddev *mddev, const char *buf, size_t len)
42834283
if (err)
42844284
export_rdev(rdev);
42854285
mddev_unlock(mddev);
4286+
if (!err)
4287+
md_new_event(mddev);
42864288
return err ? err : len;
42874289
}
42884290

0 commit comments

Comments
 (0)