diff options
author | Luke Shumaker <lukeshu@lukeshu.com> | 2022-08-27 00:51:34 -0600 |
---|---|---|
committer | Luke Shumaker <lukeshu@lukeshu.com> | 2022-08-27 00:51:34 -0600 |
commit | 0d9229ff268951d890c57a9a212afeb7fa89e732 (patch) | |
tree | f18b62bac80c5ef432fc09a5658e4ac8fca1c5e4 /lib/btrfsprogs/btrfsinspect/rebuildmappings/fuzzymatchsums.go | |
parent | cbe18889635133dde7a0014240fe896cb43f5106 (diff) |
logging
Diffstat (limited to 'lib/btrfsprogs/btrfsinspect/rebuildmappings/fuzzymatchsums.go')
-rw-r--r-- | lib/btrfsprogs/btrfsinspect/rebuildmappings/fuzzymatchsums.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/btrfsprogs/btrfsinspect/rebuildmappings/fuzzymatchsums.go b/lib/btrfsprogs/btrfsinspect/rebuildmappings/fuzzymatchsums.go index 1e47218..d326299 100644 --- a/lib/btrfsprogs/btrfsinspect/rebuildmappings/fuzzymatchsums.go +++ b/lib/btrfsprogs/btrfsinspect/rebuildmappings/fuzzymatchsums.go @@ -60,6 +60,7 @@ func fuzzyMatchBlockGroupSums(ctx context.Context, dlog.Info(ctx, "... ... done indexing") dlog.Info(ctx, "... Searching...") + numBlockgroups := len(blockgroups) for i, bgLAddr := range maps.SortedKeys(blockgroups) { blockgroup := blockgroups[bgLAddr] bgRun := SumsForLogicalRegion(logicalSums, blockgroup.LAddr, blockgroup.Size) @@ -108,7 +109,7 @@ func fuzzyMatchBlockGroupSums(ctx context.Context, lvl = dlog.LogLevelInfo } dlog.Logf(ctx, lvl, "... (%v/%v) blockgroup[laddr=%v] matches=[%s]; bestpossible=%v%% (based on %v runs)", - i+1, len(blockgroups), bgLAddr, matchesStr, int(100*bgRun.PctFull()), len(bgRun.Runs)) + i+1, numBlockgroups, bgLAddr, matchesStr, int(100*bgRun.PctFull()), len(bgRun.Runs)) if !apply { continue } @@ -129,6 +130,7 @@ func fuzzyMatchBlockGroupSums(ctx context.Context, } delete(blockgroups, bgLAddr) } + dlog.Info(ctx, "... ... done searcihng") return nil } |