diff --git a/snapraid.1 b/snapraid.1 index 6fb6c138..95c5cdf6 100644 --- a/snapraid.1 +++ b/snapraid.1 @@ -6,7 +6,11 @@ snapraid [\(hyc, \(hy\(hyconf CONFIG] .PD 0 .PP .PD - [\(hyf, \(hy\(hyfilter PATTERN] [\(hyd, \(hy\(hyfilter\(hydisk NAME] [\(hym, \(hy\(hyfilter\(hymissing] + [\(hyf, \(hy\(hyfilter PATTERN] [\(hyd, \(hy\(hyfilter\(hydisk NAME] +.PD 0 +.PP +.PD + [\(hym, \(hy\(hyfilter\(hymissing] [\(hye, \(hy\(hyfilter\(hyerror] .PD 0 .PP .PD @@ -18,7 +22,11 @@ snapraid [\(hyc, \(hy\(hyconf CONFIG] .PD 0 .PP .PD - [\(hyZ, \(hy\(hyforce\(hyzero] [\(hyE, \(hy\(hyforce\(hyempty] [\(hyU, \(hy\(hyforce\(hyuuid] [\(hyD, \(hy\(hyforce\(hydevice] + [\(hyZ, \(hy\(hyforce\(hyzero] [\(hyE, \(hy\(hyforce\(hyempty] +.PD 0 +.PP +.PD + [\(hyU, \(hy\(hyforce\(hyuuid] [\(hyD, \(hy\(hyforce\(hydevice] .PD 0 .PP .PD @@ -250,12 +258,6 @@ When this command completes, your data is SAFE. .PP At this point you can start using your array as you like, and periodically update the redundancy information running the \(a"sync\(a" command. -.PP -After a \(a"sync\(a" command, it\(cqs recommended to run a \(a"scrub\(a" command -to progressively check the old synched data. -.PP -You can verify the status of your array using the \(a"status\(a" command, -that lists all the errors found while scrubbing. .SS Pooling To have all the files in your array shown in the same directory tree, you can enable \(a"pooling\(a", that consists in creating a virtual view of all @@ -340,6 +342,41 @@ snapraid fix \(hym .PP .PD .RE +.SS Scrubbing +To progressively check the old synched data, it\(cqs recommended to always +run a \(a"scrub\(a" command after a \(a"sync\(a". +.PP +.RS 4 +snapraid scrub +.PD 0 +.PP +.PD +.RE +.PP +This command checks the oldest data in your array to ensure that no silent +error is present. Every run of the command checks about 12% of the data, +but nothing newer than 10 days. +.PP +If an error is found, the corresponding blocks are marked as bad, and listed +in the \(a"status\(a" command. +.PP +.RS 4 +snapraid status +.PD 0 +.PP +.PD +.RE +.PP +To fix them, you can use the \(a"fix\(a" command filtering for bad blocks: +.PP +.RS 4 +snapraid \(hye fix +.PD 0 +.PP +.PD +.RE +.PP +and at the next \(a"scrub\(a" the errors will disappears from the status. .SH COMMANDS SnapRAID provides four simple commands that allow to: .PD 0 @@ -394,7 +431,7 @@ as not being silent errors, but are reported anyway. .PP Any silent error identified is recorded in the content file, and it\(cqs listed in the \(a"status\(a" command until it\(cqs fixed calling -\(a"fix\(a" and then \(a"sync\(a". +\(a"fix\(a" and then \(a"scrub\(a". .PP The \(a"content\(a" file is modified to update the time of the last check of each block. @@ -510,6 +547,13 @@ This option can be used only with the \(a"check\(a" and \(a"fix\(a" commands. Note that it cannot be used with \(a"sync\(a", because \(a"sync\(a" always process the whole array. .TP +.B \(hye, \(hy\(hyfilter\(hyerror +Filters the files to process in the \(a"check\(a" and \(a"fix\(a" +commands. +It process only the files containing blocks marked with silent +errors during the \(a"scrub\(a" command, and listed in the \(a"status\(a" command. +This option can be used only with the \(a"check\(a" and \(a"fix\(a" commands. +.TP .B \(hya, \(hy\(hyaudit\(hyonly When checking, only verify the hash of the files, without doing any kind of check on the redundancy data. diff --git a/snapraid.d b/snapraid.d index 1d296b6c..35cbb951 100644 --- a/snapraid.d +++ b/snapraid.d @@ -3,10 +3,12 @@ Name{number} Synopsis :snapraid [-c, --conf CONFIG] - : [-f, --filter PATTERN] [-d, --filter-disk NAME] [-m, --filter-missing] + : [-f, --filter PATTERN] [-d, --filter-disk NAME] + : [-m, --filter-missing] [-e, --filter-error] : [-a, --audit-only] [-i, --import DIR] : [-N, --find-by-name] - : [-Z, --force-zero] [-E, --force-empty] [-U, --force-uuid] [-D, --force-device] + : [-Z, --force-zero] [-E, --force-empty] + : [-U, --force-uuid] [-D, --force-device] : [-s, --start BLKSTART] [-t, --count BLKCOUNT] : [-v, --verbose] [-l, --log FILE] : sync|status|scrub|diff|dup|pool|check|fix|rehash @@ -143,12 +145,6 @@ Getting Started At this point you can start using your array as you like, and periodically update the redundancy information running the "sync" command. - After a "sync" command, it's recommended to run a "scrub" command - to progressively check the old synched data. - - You can verify the status of your array using the "status" command, - that lists all the errors found while scrubbing. - Pooling To have all the files in your array shown in the same directory tree, you can enable "pooling", that consists in creating a virtual view of all @@ -195,6 +191,27 @@ Getting Started :snapraid fix -m + Scrubbing + To progressively check the old synched data, it's recommended to always + run a "scrub" command after a "sync". + + :snapraid scrub + + This command checks the oldest data in your array to ensure that no silent + error is present. Every run of the command checks about 12% of the data, + but nothing newer than 10 days. + + If an error is found, the corresponding blocks are marked as bad, and listed + in the "status" command. + + :snapraid status + + To fix them, you can use the "fix" command filtering for bad blocks: + + :snapraid -e fix + + and at the next "scrub" the errors will disappears from the status. + Commands SnapRAID provides four simple commands that allow to: @@ -246,7 +263,7 @@ Commands Any silent error identified is recorded in the content file, and it's listed in the "status" command until it's fixed calling - "fix" and then "sync". + "fix" and then "scrub". The "content" file is modified to update the time of the last check of each block. @@ -369,6 +386,13 @@ Options Note that it cannot be used with "sync", because "sync" always process the whole array. + -e, --filter-error + Filters the files to process in the "check" and "fix" + commands. + It process only the files containing blocks marked with silent + errors during the "scrub" command, and listed in the "status" command. + This option can be used only with the "check" and "fix" commands. + -a, --audit-only When checking, only verify the hash of the files, without doing any kind of check on the redundancy data. diff --git a/snapraid.txt b/snapraid.txt index 7858f656..f2a4201c 100644 --- a/snapraid.txt +++ b/snapraid.txt @@ -7,10 +7,12 @@ ========== snapraid [-c, --conf CONFIG] - [-f, --filter PATTERN] [-d, --filter-disk NAME] [-m, --filter-missing] + [-f, --filter PATTERN] [-d, --filter-disk NAME] + [-m, --filter-missing] [-e, --filter-error] [-a, --audit-only] [-i, --import DIR] [-N, --find-by-name] - [-Z, --force-zero] [-E, --force-empty] [-U, --force-uuid] [-D, --force-device] + [-Z, --force-zero] [-E, --force-empty] + [-U, --force-uuid] [-D, --force-device] [-s, --start BLKSTART] [-t, --count BLKCOUNT] [-v, --verbose] [-l, --log FILE] sync|status|scrub|diff|dup|pool|check|fix|rehash @@ -156,12 +158,6 @@ When this command completes, your data is SAFE. At this point you can start using your array as you like, and periodically update the redundancy information running the "sync" command. -After a "sync" command, it's recommended to run a "scrub" command -to progressively check the old synched data. - -You can verify the status of your array using the "status" command, -that lists all the errors found while scrubbing. - 4.1 Pooling ----------- @@ -212,6 +208,29 @@ Or to recover all the delete files with: snapraid fix -m +4.3 Scrubbing +------------- + +To progressively check the old synched data, it's recommended to always +run a "scrub" command after a "sync". + + snapraid scrub + +This command checks the oldest data in your array to ensure that no silent +error is present. Every run of the command checks about 12% of the data, +but nothing newer than 10 days. + +If an error is found, the corresponding blocks are marked as bad, and listed +in the "status" command. + + snapraid status + +To fix them, you can use the "fix" command filtering for bad blocks: + + snapraid -e fix + +and at the next "scrub" the errors will disappears from the status. + 5 COMMANDS ========== @@ -272,7 +291,7 @@ as not being silent errors, but are reported anyway. Any silent error identified is recorded in the content file, and it's listed in the "status" command until it's fixed calling -"fix" and then "sync". +"fix" and then "scrub". The "content" file is modified to update the time of the last check of each block. @@ -410,6 +429,13 @@ SnapRAID provides the following options: Note that it cannot be used with "sync", because "sync" always process the whole array. + -e, --filter-error + Filters the files to process in the "check" and "fix" + commands. + It process only the files containing blocks marked with silent + errors during the "scrub" command, and listed in the "status" command. + This option can be used only with the "check" and "fix" commands. + -a, --audit-only When checking, only verify the hash of the files, without doing any kind of check on the redundancy data.