Hide Forgot
Description of problem: When user runs "gluster volume bitrot <vol_name> scrub status" values for Number of Scrubbed files, Number of Unsigned files, Last completed scrub time and Duration of last scrub are shown as zero. [root@linux1]# gluster vol bitrot vol1 scrub status Volume name : vol1 State of scrub: Active Scrub impact: lazy Scrub frequency: hourly Bitrot error log location: /var/log/glusterfs/bitd.log Scrubber error log location: /var/log/glusterfs/scrub.log ========================================================= Node name: localhost Number of Scrubbed files: 0 Number of Unsigned files: 0 Last completed scrub time: 0 Duration of last scrub: 0 Error count: 1 Corrupted object's: 522a6019-bde9-4963-b1d6-bbdaf27c788a ========================================================= Node name: 10.70.36.57 Number of Scrubbed files: 0 Number of Unsigned files: 0 Last completed scrub time: 0 Duration of last scrub: 0 Error count: 0 ========================================================= Version-Release number of selected component (if applicable): How reproducible: Always Steps to Reproduce: 1. create a volume and enable bitrot on that. 2. Run the command gluster volume bitrot <vol_name> scrub status Actual results: values for Number of Scrubbed files, Number of Unsigned files, Last completed scrub time and Duration of last scrub are shown as zero. Expected results: actual Values should be shown for Number of Scrubbed files, Number of Unsigned files, Last completed scrub time and Duration of last scrub and not zeros.
REVIEW: http://review.gluster.org/14044 (features/bitrot: Introduce scrubber monitor thread) posted (#1) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14044 (features/bitrot: Introduce scrubber monitor thread) posted (#2) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14044 (features/bitrot: Introduce scrubber monitor thread) posted (#3) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14120 (glusterd/bitrot: Fix bit-rot scrub status) posted (#1) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14121 (glusterd/bitrot: Unmask scrub statistics) posted (#1) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14121 (cli/bitrot: Unmask scrub statistics) posted (#2) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14121 (cli/bitrot: Unmask scrub statistics) posted (#3) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14120 (glusterd/bitrot: Fix bit-rot scrub status) posted (#2) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14044 (features/bitrot: Introduce scrubber monitor thread) posted (#4) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14121 (cli/bitrot: Unmask scrub statistics) posted (#4) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14120 (glusterd/bitrot: Fix bit-rot scrub status) posted (#3) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14044 (features/bitrot: Introduce scrubber monitor thread) posted (#5) for review on master by Kotresh HR (khiremat)
REVIEW: http://review.gluster.org/14044 (features/bitrot: Introduce scrubber monitor thread) posted (#6) for review on master by Kotresh HR (khiremat)
COMMIT: http://review.gluster.org/14120 committed in master by Atin Mukherjee (amukherj) ------ commit 3c01660f63a32e53395e9af13f33ee5439932cdf Author: Kotresh HR <khiremat> Date: Wed Apr 20 23:49:39 2016 +0530 glusterd/bitrot: Fix bit-rot scrub status Few of the dictionary values were not allocated and set. This patch allocates them and set. Change-Id: Ic61c1209b238e45219793fd8bec92235adfbd013 BUG: 1329211 Signed-off-by: Kotresh HR <khiremat> Reviewed-on: http://review.gluster.org/14120 Smoke: Gluster Build System <jenkins.com> NetBSD-regression: NetBSD Build System <jenkins.org> CentOS-regression: Gluster Build System <jenkins.com> Reviewed-by: Venky Shankar <vshankar> Reviewed-by: Atin Mukherjee <amukherj>
COMMIT: http://review.gluster.org/14044 committed in master by Venky Shankar (vshankar) ------ commit db468e4361315a91aaeeaa14ff7e6b448e2c8599 Author: Kotresh HR <khiremat> Date: Fri Apr 29 17:45:31 2016 +0530 features/bitrot: Introduce scrubber monitor thread The patch does following changes. 1. Introduce scrubber monitor thread. 2. Move scrub status related APIs to separate file and make part of libbitrot library. Problem: Earlier, each child of the scrubber was maintaining the state machine and hence there was no way to track the start and end time of scrubbing as each brick has it's own start and end time. Also each brick was maintaining it's own timer wheel instance. It was also not possible to get scrubbed files count per session as we could not get last child which finishes scrubbing to reset it to zero. Solution: Introduce scrubber monitor thread. It does following. 1. Maintains the scrubber state machine. Earlier each child had it's own state machine. Now, only monitor maintains on behalf of all it's children. 2. Maintains the timer wheel instance. Earlier each child had it's own timer wheel instance. Now, only monitor maintains on behalf of all it's children. As a result, we can track the scrub statistics easily and correctly. Change-Id: Ic6e34ffa57984bd7a5ee81f4e263342bc1d9b302 BUG: 1329211 Signed-off-by: Kotresh HR <khiremat> Reviewed-on: http://review.gluster.org/14044 Smoke: Gluster Build System <jenkins.com> NetBSD-regression: NetBSD Build System <jenkins.org> CentOS-regression: Gluster Build System <jenkins.com> Reviewed-by: Venky Shankar <vshankar>
COMMIT: http://review.gluster.org/14121 committed in master by Atin Mukherjee (amukherj) ------ commit 232b10d68f47eee4c58f0d44891e52026b98d288 Author: Kotresh HR <khiremat> Date: Wed Apr 20 17:53:50 2016 +0530 cli/bitrot: Unmask scrub statistics Revert the commit 2a37dbd845348a774f45c4d77cffebc32c749251 The scrub statistics were masked because of inaccurate stats. Now with http://review.gluster.org/#/c/14044/ it's fixed, hence unmasking it. Change-Id: Iffff5f48eb8121b617af82ecfb70bec5b2772c23 BUG: 1329211 Signed-off-by: Kotresh HR <khiremat> Reviewed-on: http://review.gluster.org/14121 Smoke: Gluster Build System <jenkins.com> NetBSD-regression: NetBSD Build System <jenkins.org> CentOS-regression: Gluster Build System <jenkins.com> Reviewed-by: Venky Shankar <vshankar> Reviewed-by: Atin Mukherjee <amukherj>
REVIEW: http://review.gluster.org/14146 (features/bitrot: Fix Compilation Warning!!!) posted (#1) for review on master by Kotresh HR (khiremat)
*** Bug 1285989 has been marked as a duplicate of this bug. ***
v3.10.0 Contains the Fix