diff options
author | Allan Jude <[email protected]> | 2021-11-30 09:46:25 -0500 |
---|---|---|
committer | GitHub <[email protected]> | 2021-11-30 07:46:25 -0700 |
commit | 2a673e76a928cca4df7794cdcaa02e0be149c4da (patch) | |
tree | 016afa631bb0d98f55b01e93ab80842fe6ffda27 /lib/libzfs/os/freebsd/libzfs_compat.c | |
parent | 5f64bf7fdeebfbad50e98c6cd0c3a361a9aecabc (diff) |
Vdev Properties Feature
Add properties, similar to pool properties, to each vdev.
This makes use of the existing per-vdev ZAP that was added as
part of device evacuation/removal.
A large number of read-only properties are exposed,
many of the members of struct vdev_t, that provide useful
statistics.
Adds support for read-only "removing" vdev property.
Adds the "allocating" property that defaults to "on" and
can be set to "off" to prevent future allocations from that
top-level vdev.
Supports user-defined vdev properties.
Includes support for properties.vdev in SYSFS.
Co-authored-by: Allan Jude <[email protected]>
Co-authored-by: Mark Maybee <[email protected]>
Reviewed-by: Matthew Ahrens <[email protected]>
Reviewed-by: Mark Maybee <[email protected]>
Signed-off-by: Allan Jude <[email protected]>
Closes #11711
Diffstat (limited to 'lib/libzfs/os/freebsd/libzfs_compat.c')
-rw-r--r-- | lib/libzfs/os/freebsd/libzfs_compat.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/libzfs/os/freebsd/libzfs_compat.c b/lib/libzfs/os/freebsd/libzfs_compat.c index f143f9cb6..e3f17662a 100644 --- a/lib/libzfs/os/freebsd/libzfs_compat.c +++ b/lib/libzfs/os/freebsd/libzfs_compat.c @@ -305,6 +305,10 @@ zfs_jail(zfs_handle_t *zhp, int jailid, int attach) zfs_error_aux(hdl, dgettext(TEXT_DOMAIN, "bookmarks can not be jailed")); return (zfs_error(hdl, EZFS_BADTYPE, errbuf)); + case ZFS_TYPE_VDEV: + zfs_error_aux(hdl, dgettext(TEXT_DOMAIN, + "vdevs can not be jailed")); + return (zfs_error(hdl, EZFS_BADTYPE, errbuf)); case ZFS_TYPE_POOL: case ZFS_TYPE_FILESYSTEM: /* OK */ |