]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: clear INCONSISTENT if scrub detects no errors
authorSage Weil <sage@newdream.net>
Fri, 17 Dec 2010 18:59:45 +0000 (10:59 -0800)
committerSage Weil <sage@newdream.net>
Fri, 17 Dec 2010 18:59:45 +0000 (10:59 -0800)
Signed-off-by: Sage Weil <sage@newdream.net>
src/osd/PG.cc

index 76e2a05898f035eeb45c55e2c0f83181eb294d78..6502b73174b3f5752abaf333a7f6438ebed723d0 100644 (file)
@@ -3310,7 +3310,7 @@ void PG::scrub()
     ss << ", " << fixed << " fixed";
   osd->get_logclient()->log(errors ? LOG_ERROR:LOG_INFO, ss);
 
-  if (!(errors - fixed) && repair)
+  if (errors == 0 || (repair && (errors - fixed) == 0))
     state_clear(PG_STATE_INCONSISTENT);
   state_clear(PG_STATE_REPAIR);