Commit Graph

1744 Commits

Author SHA1 Message Date
Joe Thornber
e9fbcc31de [thin_dump (rust)] First pass at thin_dump.
Doesn't include --repair.

This includes <def> and <ref> sections for shared regions.
2020-09-28 15:45:13 +01:00
Joe Thornber
a88ae3ca18 [thin_check (rust)] factor out device detail 2020-09-25 09:59:16 +01:00
Joe Thornber
66b6a1ba48 [thin_check (rust)] --superblock-only, --skip-mappings, INFO fields 2020-09-24 13:55:58 +01:00
Joe Thornber
34052c540c [thin_check (rust)] Reinstate walk_node_threaded 2020-09-24 09:40:38 +01:00
Joe Thornber
f4c3098e02 [thin_check (rust)] fix bug in key range splitting.
Ranges were not being ommitted when a block was ommitted due to
being shared and already visited.
2020-09-22 10:47:23 +01:00
Joe Thornber
819fc6d54c [thin_explore] accept a node path on the command line
Helpful to examine thin_check failures.
2020-09-22 10:47:04 +01:00
Joe Thornber
b193d19603 [thin_check (rust)] output complete node paths with errors.
This can be used with thin_explore
2020-09-18 11:16:09 +01:00
Joe Thornber
bc058f8baf [thin_check (rust)] BTree values must now implement Copy 2020-09-18 10:06:33 +01:00
Joe Thornber
bcfb9a73a1 [thin_explore] display ranges where possible 2020-09-18 09:12:51 +01:00
Joe Thornber
8493cf7081 [thin_explore] First code drop 2020-09-16 15:10:01 +01:00
Joe Thornber
5168621f02 [thin_check (rust)] Optimise SyncIoEngine
*_many no longer get/put for each block
2020-09-02 13:28:16 +01:00
Joe Thornber
44142f657a [thin_check (rust)] Add error handling to io_engine interface 2020-09-02 12:57:47 +01:00
Joe Thornber
b82307d8a5 [thin_check (rust)] drop O_DIRECT for the sync_io engine.
O_DIRECT slows us down, and there's no correctness reason for having it.
2020-08-21 11:39:41 +01:00
Joe Thornber
cda92de441 [thin_check (rust)] Add a threaded version of btree walk.
Bottom level mappings use this if there are few devices.  Performance
is a bit slower for io_uring, and much slower for sync io (which I think
is due to io scheduling which I can't do much about).
2020-08-21 10:10:49 +01:00
Joe Thornber
b01a0a46d1 [thin_metadata_pack/unpack] Use Vec::with_capacity() to avoid reallocs.
Gives a small speed boost to both pack and unpack.
2020-08-21 09:14:54 +01:00
Joe Thornber
c9a759b4e8 [thin_check (rust)] Use vec::with_capacity() to avoid reallocations. 2020-08-21 09:00:21 +01:00
Joe Thornber
2cc2dffab5 [thin_check (rust)] Make NodeVisitor::visit non mut.
Preparation for making btree_walk multithreaded
2020-08-20 11:05:14 +01:00
Joe Thornber
a1c206b774 [thin_check (rust)] NodeVisitor only needs to see leaf nodes 2020-08-20 10:55:38 +01:00
Joe Thornber
936e06e132 [thin_check (rust)] Remove some unused params from NodeVisitor::visit 2020-08-20 10:46:06 +01:00
Joe Thornber
1999343d2f [thin_check (rust)] squash a couple of warnings 2020-08-20 10:33:02 +01:00
Joe Thornber
7834d661e2 [thin_check (rust)] auto repair space map leaks 2020-08-19 14:31:01 +01:00
Joe Thornber
cdd0beb527 [thin_check (rust)] Change io_engine trait to use slices rather than Vecs 2020-08-18 12:57:05 +01:00
Joe Thornber
2aa6859502 [thin_check (rust)] add write support to io_engine 2020-08-18 12:52:16 +01:00
Joe Thornber
67a54b4ebc [thin_check (rust)] add --auto-repair switch 2020-08-18 11:47:42 +01:00
Joe Thornber
8eec84fbec [thin_check (rust)] introduce ASpaceMap type alias 2020-08-18 11:06:15 +01:00
Joe Thornber
04f3ba5a33 [thin_check (rust)] Pass ctx to check_space_map 2020-08-18 10:59:04 +01:00
Joe Thornber
4beb2db337 [thin_check (rust)] Factor out check_mapping_bottom_level 2020-08-18 10:53:11 +01:00
Joe Thornber
239ae6b6ec [thin_check (rust)] factor out spawn_progress_thread 2020-08-18 09:48:51 +01:00
Joe Thornber
e8d7e5cf1e [thin_check (rust)] move report creation to top level 2020-08-17 16:05:06 +01:00
Joe Thornber
5743e3e9ba [thin_check (rust)] Add title method to reports 2020-08-17 15:36:21 +01:00
Joe Thornber
9995751dde [thin_check (rust)] Provide 3 different report types.
ProgressBar for interactive use.
Simple for when not a tty
and quiet for -q
2020-08-17 13:10:32 +01:00
Joe Thornber
7466cd7182 [functional-tests (rust)] TestDir now creates dir in ./
O_DIRECT doesn't work with /tmp/
2020-08-14 10:54:31 +01:00
Joe Thornber
e1cfc3866b [thin_check (rust)] Mappings top level weren't being ref counted 2020-08-13 14:43:19 +01:00
Joe Thornber
092447d17a [thin_check (rust)] remove some dead code 2020-08-13 14:30:04 +01:00
Joe Thornber
2fa732a93c [functional tests] Port some of Hank's sh tests to Rust.
Run with 'cargo test'
2020-08-13 14:20:29 +01:00
Joe Thornber
a8a2f560ec [build] add symlinks for thin_generate_{mappings/damage} 2020-08-13 13:47:51 +01:00
Joe Thornber
b0e7520fbf [thin/superblock (rust)] Unpack flags 2020-08-13 13:46:07 +01:00
Joe Thornber
c254ebe384 [functional-tests] Port 3 --auto-repair tests from Scheme to Rust 2020-08-12 13:03:01 +01:00
Joe Thornber
5a16f21199 [functional tests] Fixup a few tests that broke when we bumped the version nr. 2020-08-12 12:33:16 +01:00
Joe Thornber
bf202d076b Merge branch '2020-06-13-thin-check-rewrite' 2020-08-12 11:18:28 +01:00
Joe Thornber
d6d93c3157 bump version to 0.9.0 2020-08-12 10:46:26 +01:00
Joe Thornber
2860b4c0b1 [thin_check] rename --fix-metadata-leaks to --auto-repair
This flag will cover all trivial fixes, such as data leaks.
2020-08-12 10:45:20 +01:00
Joe Thornber
ebcfc322c0 [build] Update CHANGES file 2020-08-12 10:35:03 +01:00
Joe Thornber
d9965a3906
Merge pull request #149 from mingnus/thin-check-fix-metadata-leaks
thin_check enhancements
2020-08-12 10:28:26 +01:00
Joe Thornber
afa3f2f04d [thin_check (rust)] Rename Spinner -> Reporter 2020-08-12 10:25:06 +01:00
Ming-Hung Tsai
6c90f9483e [metadata_checker] Support in-place metadata space map modification 2020-08-12 16:57:16 +08:00
Ming-Hung Tsai
0349e9c9e2 [space-maps/disk] Show the block address in exception string 2020-08-12 16:57:16 +08:00
Ming-Hung Tsai
1cfdcd58c5 [metadata_checker] Disable checking data block ref-counts due to performance concerns 2020-08-12 16:57:16 +08:00
Joe Thornber
544335ae4a [thin_check (rust)] Send all reporting through the Spinner.
This means the spinner doesn't overwrite messages.
2020-08-12 09:35:21 +01:00
Ming-Hung Tsai
b16ff123b7 [thin] Stop metadata counting on the first error 2020-08-12 15:56:26 +08:00