aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/zpool/zpool_main.c
diff options
context:
space:
mode:
authorAllan Jude <[email protected]>2021-12-16 14:56:22 -0500
committerGitHub <[email protected]>2021-12-16 11:56:22 -0800
commitf6a0dac84af2fba9c306a3a307ea7aafcbe32d2b (patch)
treea60d820228fe669dacc8f1687251fcc98a22c621 /cmd/zpool/zpool_main.c
parent2300621dc7450adccf86ddbf397c72f8e5e2d76c (diff)
zfs list: Allow more fields in ZFS_ITER_SIMPLE mode
If the fields to be listed and sorted by are constrained to those populated by dsl_dataset_fast_stat(), then zfs list is much faster, as it does not need to open each objset and reads its properties. A previous optimization by Pawel Dawidek (0cee24064a79f9c01fc4521543c37acea538405f) took advantage of this to make listing snapshot names sorted only by name much faster. However, it was limited to `-o name -s name`, this work extends this optimization to work with: - name - guid - createtxg - numclones - inconsistent - redacted - origin and could be further extended to any other properties supported by dsl_dataset_fast_stat() or similar, that do not require extra locking or reading from disk. Reviewed-by: Mark Maybee <[email protected]> Reviewed-by: Ryan Moeller <[email protected]> Reviewed-by: Brian Behlendorf <[email protected]> Reviewed-by: Pawel Jakub Dawidek <[email protected]> Signed-off-by: Allan Jude <[email protected]> Closes #11080
Diffstat (limited to 'cmd/zpool/zpool_main.c')
-rw-r--r--cmd/zpool/zpool_main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd/zpool/zpool_main.c b/cmd/zpool/zpool_main.c
index 4e2f828cb..dd5c3f205 100644
--- a/cmd/zpool/zpool_main.c
+++ b/cmd/zpool/zpool_main.c
@@ -8814,7 +8814,7 @@ check_unsupp_fs(zfs_handle_t *zhp, void *unsupp_fs)
(*count)++;
}
- zfs_iter_filesystems(zhp, check_unsupp_fs, unsupp_fs);
+ zfs_iter_filesystems(zhp, 0, check_unsupp_fs, unsupp_fs);
zfs_close(zhp);