thin_check(8)
β¨ thin_check(8) β System Manager's Manual β¨
π NAME
thin_check β validates thin provisioning metadata on a device or file π
πΈ SYNOPSIS
thin_check [options] {device|file}
π DESCRIPTION
okay so thin_check is the tool that goes through thin provisioning metadata created by the device-mapper thin provisioning target, on a device or a file. it's giving thorough checkup energy π©Ίβ¨
bestie, you cannot run it on live metadata unless you use the --metadata-snapshot option. no cap, don't skip this part π
π¦ OPTIONS
-q,--quietβ shh, suppresses the output messages so you only get the exit code π€«-h,--helpβ prints help and exits πββοΈ-V,--versionβ outputs version information and exits π§--super-block-onlyβ only checks the superblock, lowkey the quick version π--skip-mappingsβ skips checking the block mappings, which make up the bulk of the metadata π--ignore-non-fatal-errorsβ will only return a non-zero exit code if it finds a fatal error π
okay so a nonfatal error is something like an incorrect data block reference count that makes a block look allocated when it actually isn't. ignoring errors for a long time is NOT advised, bestie. you really should be using thin_repair to fix them π
--clear-needs-check-flagβ clears theneeds_checkflag in the superblock β¨
the kernel may set a flag that forces the pool to be checked before it's next activated. use this switch to clear the flag if the check succeeds. if the metadata check fails, the flag is NOT cleared and you need to run thin_repair to fix any issues. after thin_repair succeeds, you may run thin_check again π«Ά
--metadata-snapshot,-mβ checks the metadata snapshot πΈ
this checks the devices tree and mappings in a metadata snapshot. the snap doesn't contain space maps, so those won't be checked. this one can be used on live metadata, so it's the main character move π
--auto-repairβ automatically repairs any trivial issues found with the metadata π§
currently it only fixes metadata leaks π«§
--override-mapping-root <block>β specifies a mapping root to use π§©
bestie, don't use this. it overrides what's specified in the superblock. only use it if you REALLY understand the metadata format and you're trying to recover damaged metadata π
π EXAMPLE
analyses thin provisioning metadata on logical volume /dev/vg/metadata:
$ thin_check /dev/vg/metadata
the device must not be actively used by the target when running π ββοΈ
π©Ί DIAGNOSTICS
thin_check returns an exit code of 0 for success or 1 for error. that's the whole vibe β
π SEE ALSO
thin_dump(8), thin_repair(8), thin_restore(8), thin_rmap(8), thin_metadata_size(8) π
π«Ά AUTHOR
Joe Thornber <ejt@redhat.com>, Heinz Mauelshagen <heinzm@redhat.com> π
ttyl bestie, this was thin_check(8) from the Device Mapper Tools section of the System Manager's Manual ππ
π¦ where this page comes from
- alpine 3.24: thin-provisioning-tools-doc 1.3.2-r0 Β· GPL-3.0-only
- arch rolling: thin-provisioning-tools 1.3.4-1 Β· GPL-3.0-only
- centos-stream 10: device-mapper-persistent-data 1.3.4-1.el10 Β· GPL-3.0-only AND (0BSD OR MIT OR Apache-2.0) AND Apache-2.0 AND (Apache-2.0 OR MIT) AND (Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT) AND BSD-3-Clause AND MIT AND (MIT OR Apache-2.0) AND (MIT OR Zlib OR Apache-2.0) AND (Unlicense OR MIT) AND (Zlib OR Apache-2.0 OR MIT)
- centos-stream 9: device-mapper-persistent-data 1.1.0-1.el9 Β· GPL-3.0-only AND (0BSD OR MIT OR Apache-2.0) AND Apache-2.0 AND (Apache-2.0 OR MIT) AND (Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT) AND BSD-3-Clause AND MIT AND (MIT OR Apache-2.0) AND (MIT OR Zlib OR Apache-2.0) AND (Unlicense OR MIT) AND (Zlib OR Apache-2.0 OR MIT)
- debian trixie: thin-provisioning-tools 1.1.0-4+b1 Β· GPL-3.0-or-later
- fedora 43: device-mapper-persistent-data 1.1.0-4.fc43 Β· GPL-3.0-only AND (0BSD OR MIT OR Apache-2.0) AND Apache-2.0 AND (Apache-2.0 OR MIT) AND (Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT) AND BSD-3-Clause AND MIT AND (MIT OR Apache-2.0) AND (MIT OR Zlib OR Apache-2.0) AND (Unlicense OR MIT) AND (Zlib OR Apache-2.0 OR MIT)
- fedora 43: device-mapper-persistent-data 1.3.3-1.fc43
- fedora 43: device-mapper-persistent-data 1.3.4-1.fc43 Β· GPL-3.0-only AND (0BSD OR MIT OR Apache-2.0) AND Apache-2.0 AND (Apache-2.0 OR MIT) AND (Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT) AND BSD-3-Clause AND MIT AND (MIT OR Apache-2.0) AND (MIT OR Zlib OR Apache-2.0) AND (Unlicense OR MIT) AND (Zlib OR Apache-2.0 OR MIT)
- fedora 44: device-mapper-persistent-data 1.3.1-3.fc44 Β· GPL-3.0-only AND (0BSD OR MIT OR Apache-2.0) AND Apache-2.0 AND (Apache-2.0 OR MIT) AND (Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT) AND BSD-3-Clause AND MIT AND (MIT OR Apache-2.0) AND (MIT OR Zlib OR Apache-2.0) AND (Unlicense OR MIT) AND (Zlib OR Apache-2.0 OR MIT)
- fedora 44: device-mapper-persistent-data 1.3.3-1.fc44
- fedora 44: device-mapper-persistent-data 1.3.4-1.fc44 Β· GPL-3.0-only AND (0BSD OR MIT OR Apache-2.0) AND Apache-2.0 AND (Apache-2.0 OR MIT) AND (Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT) AND BSD-3-Clause AND MIT AND (MIT OR Apache-2.0) AND (MIT OR Zlib OR Apache-2.0) AND (Unlicense OR MIT) AND (Zlib OR Apache-2.0 OR MIT)
- opensuse-leap 16.0: thin-provisioning-tools 1.1.0-160000.2.2 Β· GPL-3.0-only
- opensuse-leap 16.0: thin-provisioning-tools 1.1.0-160000.2.2 Β· GPL-3.0-only
- opensuse-leap 16.0: thin-provisioning-tools 1.1.0-160000.2.2 Β· GPL-3.0-only
- opensuse-leap 16.0: thin-provisioning-tools 1.1.0-160000.2.2 Β· GPL-3.0-only
- ubuntu questing: thin-provisioning-tools 1.1.0-4ubuntu1 Β· GPL-3.0-or-later
- ubuntu resolute: thin-provisioning-tools 1.1.0-4ubuntu2 Β· GPL-3.0-or-later
- ubuntu stonking: thin-provisioning-tools 1.1.0-5.1ubuntu1 Β· GPL-3.0-or-later
- π girlified by anthropic/claude-haiku-5.5 on : a language model's rewrite of the original, under its terms