Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have created a raid array say RAID5 or RAID10 with four drives. I wish to force resync of the same array, Please let me know the mdadm command for the same.

Also, in case of RAID1 (mirroring) what is being done as part of resync. Is it basically replication of same chunk of data in two drives? Linux is the OS used.

Thanks.

share|improve this question

1 Answer 1

To resync an mdadm RAID-1 (which, as you suspect, is block-by-block checking one drive against the other, and replicating one to the other when they differ) you can do

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

substituting md1, md2, etc. for md0 as appropriate.

Whilst I can't testify to it, this kernel patch from 2008 makes it pretty clear to me that this is also intended to work for RAID-5.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.