Files
mirror_zfs/cmd
Rob Norris 4c84b77bc4 pool_iter_refresh: don't flag existing pools as refreshed
zpool_iter() passes the callback a new instance of zpool_handle_t each
time, so the existing handle in the pool_list AVL never actually gets a
refresh. Internally, that means its zpool_config is never updated, and
the old config is never moved to zpool_old_config. As a result,
print_iostat() never sees any updated config, and so repeats the first
line forever.

This is the simplest workaround: just don't mark existing pools as
refreshed. pool_list_refresh() will see this and refresh them.
The downside is a second call to ZFS_IOC_POOL_STATS for existing pools,
because zpool_iter() just called it for the handle we threw away.

Sponsored-by: Klara, Inc.
Sponsored-by: Wasabi Technology, Inc.
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Rob Norris <rob.norris@klarasystems.com>
Closes #17807
2025-10-21 09:50:43 -07:00
..
2025-03-13 17:56:27 -07:00
2025-09-11 15:58:59 -07:00
2025-03-13 17:56:27 -07:00
2025-09-10 15:01:20 -07:00
2025-03-13 17:56:27 -07:00
2025-09-10 15:01:20 -07:00
2025-03-13 17:56:27 -07:00
2025-03-13 17:56:27 -07:00