]> granicus.if.org Git - zfs/commit
Add zfs create dryrun
authorMike Gerdts <mike.gerdts@joyent.com>
Tue, 16 Jul 2019 18:19:24 +0000 (13:19 -0500)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 16 Jul 2019 18:19:24 +0000 (11:19 -0700)
commitd45d7f08fa56f94fc9577a6578cb411071a42e8d
treef841ba287b8040cb4930a60dae553b897d1972d8
parent93e28d661e1d704a9cada86ef2bc4763a6ef3be7
Add zfs create dryrun

Adds the ability to sanity check zfs create arguments and to see the
value of any additional properties that will local to the dataset.  For
example, automation that may need to adjust quota on a parent filesystem
before creating a volume may call `zfs create -nP -V <size> <volume>` to
obtain the value of refreservation.  This adds the following options to
zfs create:

- -n dry-run (no-op)
- -v verbose
- -P parseable (implies verbose)

Reviewed-by: Ryan Moeller <ryan@ixsystems.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Matt Ahrens <matt@delphix.com>
Reviewed-by: Jerry Jelinek <jerry.jelinek@joyent.com>
Signed-off-by: Mike Gerdts <mike.gerdts@joyent.com>
Closes #8974
cmd/zfs/zfs_main.c
man/man8/zfs.8
tests/runfiles/linux.run
tests/zfs-tests/tests/functional/cli_root/zfs_create/Makefile.am
tests/zfs-tests/tests/functional/cli_root/zfs_create/zfs_create_dryrun.ksh [new file with mode: 0755]
tests/zfs-tests/tests/functional/cli_root/zfs_create/zfs_create_verbose.ksh [new file with mode: 0755]