Re: a question about how to repair raid5

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon Nov 26, 2012 at 08:32:38 +0800, hanguozhong wrote:

> Hi, every one:
> I have a question about how to repair raid5.
> Days ago, I received a email from the monitor of mdadm. 
> The email told me that there were lots of mismatch_cnt in the array. 
> Then I tried to find the solution of this problem on Google. Most solutions were as the following:
> 
> #echo repair /sys/block/md0/md/sync_action
> #echo "check" > /sys/block/md0/md/sync_action
> #cat /sys/block/md0/md/mismatch_cnt
> 
> I did repair the array like the above. 
> But I found that it took lots of time to "repair" and "check" the array. 
> Why there was a "check" after "repair"I did not know. And it spent as much time as "repair".
> Is it redundant? Anyone can help me?

That's the correct process, yes. The "check" will verify whether the
parity block for each stripe is correct, whereas the "repair" will also
rewrite any parity blocks which don't match. You rerun the "check" after
the "repair" to ensure that everything has been repaired correctly (if
there's still mismatches then it would point towards a problem with your
setup somewhere). Both are doing a full read of all disks, so will take
about the same time (the number of additional writes that the "repair"
needs to do should not impact on the time significantly).

HTH,
    Robin

-- 
     ___        
    ( ' }     |       Robin Hill        <robin@xxxxxxxxxxxxxxx> |
   / / )      | Little Jim says ....                            |
  // !!       |      "He fallen in de water !!"                 |

Attachment: pgpqIutyfXL9O.pgp
Description: PGP signature


[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux