mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 10:37:35 +03:00
Add no-upgrade featureflag
Adds a featureflag that is not enabled during upgrades unless listed explicitly. This is useful for features that could cause issues unless applied carefully; for example, a feature that could make a root pool unbootable if bootloaders don't yet have support for it. Sponsored-by: Klara, Inc. Sponsored-by: Wasabi Technology, Inc. Reviewed-by: Alexander Motin <mav@FreeBSD.org> Reviewed-by: Tony Hutter <hutter2@llnl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Rob Norris <rob.norris@klarasystems.com> Reviewed-by: Allan Jude <allan@klarasystems.com> Signed-off-by: Paul Dagnelie <paul.dagnelie@klarasystems.com> Closes #17004
This commit is contained in:
committed by
Brian Behlendorf
parent
4c2a7f85d5
commit
e845be28e7
+10
-3
@@ -11330,7 +11330,8 @@ upgrade_enable_all(zpool_handle_t *zhp, int *countp)
|
||||
const char *fname = spa_feature_table[i].fi_uname;
|
||||
const char *fguid = spa_feature_table[i].fi_guid;
|
||||
|
||||
if (!spa_feature_table[i].fi_zfs_mod_supported)
|
||||
if (!spa_feature_table[i].fi_zfs_mod_supported ||
|
||||
(spa_feature_table[i].fi_flags & ZFEATURE_FLAG_NO_UPGRADE))
|
||||
continue;
|
||||
|
||||
if (!nvlist_exists(enabled, fguid) && requested_features[i]) {
|
||||
@@ -11485,7 +11486,11 @@ upgrade_list_disabled_cb(zpool_handle_t *zhp, void *arg)
|
||||
"Note that the pool "
|
||||
"'compatibility' feature can be "
|
||||
"used to inhibit\nfeature "
|
||||
"upgrades.\n\n"));
|
||||
"upgrades.\n\n"
|
||||
"Features marked with (*) are not "
|
||||
"applied automatically on upgrade, "
|
||||
"and\nmust be applied explicitly "
|
||||
"with zpool-set(7).\n\n"));
|
||||
(void) printf(gettext("POOL "
|
||||
"FEATURE\n"));
|
||||
(void) printf(gettext("------"
|
||||
@@ -11499,7 +11504,9 @@ upgrade_list_disabled_cb(zpool_handle_t *zhp, void *arg)
|
||||
poolfirst = B_FALSE;
|
||||
}
|
||||
|
||||
(void) printf(gettext(" %s\n"), fname);
|
||||
(void) printf(gettext(" %s%s\n"), fname,
|
||||
spa_feature_table[i].fi_flags &
|
||||
ZFEATURE_FLAG_NO_UPGRADE ? "(*)" : "");
|
||||
}
|
||||
/*
|
||||
* If they did "zpool upgrade -a", then we could
|
||||
|
||||
Reference in New Issue
Block a user