summaryrefslogtreecommitdiffstats
path: root/xlators/features/bit-rot/src/bitd/bit-rot.c
diff options
context:
space:
mode:
authorVenky Shankar <vshankar@redhat.com>2015-05-04 11:58:23 +0530
committerVijay Bellur <vbellur@redhat.com>2015-05-08 00:08:17 -0700
commit9dcb6e07cf432a047654a3f04a23a438fe969bfb (patch)
tree73a2c0bbdddc795d572d35e3031a9a3707394139 /xlators/features/bit-rot/src/bitd/bit-rot.c
parent7c0c184be28e0cba08645c7106c6901b444651c9 (diff)
features/bitrot: Scrubber pause/resume
With logical scan/scrub split, pausing filesystem scrubber is an override to the thread throttling mechanism, which effectively throttles "down" number of scrubber threads to zero. This causes scanner to wait until threads are spawned again (when resumed) thereby continuing where it left off (since the file tree walk stack is effectively preserved when the main scanner thread is waiting for scrubbers to consume scanned entries). The only catch is when scrubber daemon restarts: file tree walk stack is lost and scrubbing initiates from root. This is probably OK for now (can be changed later to persist parent directory information before entering pause state). Change-Id: I5109a749b7fccd0f5367765078f46e6522dd32a1 BUG: 1208131 Signed-off-by: Venky Shankar <vshankar@redhat.com> Reviewed-on: http://review.gluster.org/10521 Reviewed-by: Vijay Bellur <vbellur@redhat.com> Tested-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'xlators/features/bit-rot/src/bitd/bit-rot.c')
-rw-r--r--xlators/features/bit-rot/src/bitd/bit-rot.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/xlators/features/bit-rot/src/bitd/bit-rot.c b/xlators/features/bit-rot/src/bitd/bit-rot.c
index eea81aec53a..5638b0f348b 100644
--- a/xlators/features/bit-rot/src/bitd/bit-rot.c
+++ b/xlators/features/bit-rot/src/bitd/bit-rot.c
@@ -1626,6 +1626,7 @@ struct volume_options options[] = {
},
{ .key = {"scrub-state"},
.type = GF_OPTION_TYPE_STR,
+ .default_value = "active",
.description = "Pause/Resume scrub. Upon resume, scrubber "
"continues from where it left off.",
},