In the /etc/lvm/lvm.conf, we have: "thin_check_options = [ "-q", "--clear-needs-check-flag", "--super-block-only" ]" It prevents the activation of the thin volume: lvchange -vay /dev/L5TTGI4V6ZD3WL7P Activating logical volume L5TTGI4V6ZD3WL7P/thinpool. activation/volume_list configuration setting not defined: Checking only host tags for L5TTGI4V6ZD3WL7P/thinpool. Creating L5TTGI4V6ZD3WL7P-thinpool_tmeta Loading table for L5TTGI4V6ZD3WL7P-thinpool_tmeta (254:4). Resuming L5TTGI4V6ZD3WL7P-thinpool_tmeta (254:4). Creating L5TTGI4V6ZD3WL7P-thinpool_tdata Loading table for L5TTGI4V6ZD3WL7P-thinpool_tdata (254:5). Resuming L5TTGI4V6ZD3WL7P-thinpool_tdata (254:5). Executing: /sbin/thin_check -q --clear-needs-check-flag --skip-mappings /dev/mapper/L5TTGI4V6ZD3WL7P-thinpool_tmeta cannot perform fix without a full examination Usage: thin_check [options] {device|file} Options: {-q|--quiet} {-h|--help} {-V|--version} {-m|--metadata-snap} {--auto-repair} {--override-mapping-root} {--clear-needs-check-flag} {--ignore-non-fatal-errors} {--skip-mappings} {--super-block-only} /sbin/thin_check failed: 1 Check of pool L5TTGI4V6ZD3WL7P/thinpool failed (status:1). Manual repair required! Removing L5TTGI4V6ZD3WL7P-thinpool_tmeta (254:4) Removing L5TTGI4V6ZD3WL7P-thinpool_tdata (254:5) The problem has already been reported in redhat bug repo: https://bugzilla.redhat.com/show_bug.cgi?id=2028905 A patch on top of 0.9.0 already fixes the issue, pulling it in in a jiffy.
Created attachment 865380 [details, diff] Patch to allow thincheck to activate thin volume The patch allows thincheck to accept --clear-needs-check and --skip-mappings together. From the patch that solves the issue: """ Although it is not recommended to clear the flag without a full examination, however, the usage has been documented as an approach to reduce lvchange run time [1]. For the purpose of backward compatibility and avoiding boot failure after upgrading thin_check [2], the limitation is now removed. [1] https://wiki.archlinux.org/index.php/LVM#Thinly-provisioned_root_volume_device_times_out [2] Community feedback on previous commit: https://github.com/jthornber/thin-provisioning-tools/commit/b278f4f """
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=898bc97f64af4b18e2863216cf4239070388dbb5 commit 898bc97f64af4b18e2863216cf4239070388dbb5 Author: Gwendal Grignou <gwendal@chromium.org> AuthorDate: 2023-07-11 16:08:38 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2023-09-06 08:34:01 +0000 sys-block/thin-provisioning-tools: Allow valid flag combination Prevent issue with activating thinvolume with valid but dangerous flag setting. See https://bugzilla.redhat.com/show_bug.cgi?id=2028905. The fix includes 2 upstream patches: commit 1fe8a0dbde9f5 ("[thin_check] Allow using --clear-needs-check and --skip-mappings together") commit 9f3823c97dc0b ("[metadata_checker] Rename function to reflect command line changes") In the first patch, the test code (thin_check.rs) is removed since 0.9.0 does not support rust yet. Closes: https://bugs.gentoo.org/910223 Signed-off-by: Gwendal Grignou <gwendal@chromium.org> Closes: https://github.com/gentoo/gentoo/pull/31885 Signed-off-by: Sam James <sam@gentoo.org> ...ecker-Rename-function-to-reflect-command-.patch | 66 ++++++++ ...Allow-using-clear-needs-check-and-skip-ma.patch | 187 +++++++++++++++++++++ .../thin-provisioning-tools-0.9.0-r3.ebuild | 69 ++++++++ 3 files changed, 322 insertions(+)
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9551b6b0c63ca061fbb86d144495e6efa48696b4 commit 9551b6b0c63ca061fbb86d144495e6efa48696b4 Author: Sam James <sam@gentoo.org> AuthorDate: 2023-09-06 08:42:12 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2023-09-06 08:46:36 +0000 profiles/features/wd40: tweak thin-provisioning-tools mask Be slightly nicer for now as people on wd40 arches might rely on this for booting. Not that we can really do much about this in the long-term, especially given e.g. bug #910223 shows that it's not exactly a finished product (as well as the constant rewrites). Bug: https://bugs.gentoo.org/910223 Signed-off-by: Sam James <sam@gentoo.org> profiles/features/wd40/package.mask | 2 +- profiles/features/wd40/package.use.mask | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)