zdb lists old pool version after pool upgrade
After upgrading a pool from version 22 to 28, zdb still lists the pool as being version 22. It appears the issues is isolated to zdb only.
The pool is in fact truly upgraded. zfs get version <poolname> lists version 28.
Live media that has an earlier pool version is unable to import said pool, listing it as "created with a newer pool version."
Updated by Bryan Leaman over 10 years ago
I easily reproduced this issue by creating a zpool as version 22 and then upgrading it to 28. zdb still reported version 22. Exporting and importing the pool caused zdb to report version 28.
I'm thinking the upgrade process is not updating the zpool.cache file. Executing zdb without any options appears to call dump_cachefile(spa_config_path).
Updated by n2deep n2deep over 10 years ago
The main concern I have right now is this behavior on a systems rpool. One cannot just export/import the rpool on a running system.
On the test machine I describe above, after several reboots spanned over around two weeks, the rpool reported as version 22 by zdb, "automagically" started being reported as version 28 by zdb. For other reasons, the machine went through at least six full reboots (spanned over days) after the rpool was upgraded to version 28, and I know zdb did not report it correctly after the first three as I checked each of those times.