How to force re-check of mdadm RAID on Linux

To force a check of md0, use the following command:

echo check > /sys/block/md0/md/sync_action

check is a read-only check and does not perform repairs. Consider using repair instead:

echo repair > /sys/block/md0/md/sync_action

You can stop the operation using idle if it interferes with your work:

echo idle > /sys/block/md0/md/sync_action