HomeFreeBSD

zpool command complains about /etc/exports.d

Description

zpool command complains about /etc/exports.d

If the /etc/exports.d directory does not exist, then we should only
create it when we're performing an action which already requires root
privileges.

This commit moves the directory creation to the enable/disable code
path which ensures that we have the appropriate privileges.

Reviewed-by: Richard Elling <Richard.Elling@RichardElling.com>
Reviewed-by: Matthew Ahrens <mahrens@delphix.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: George Wilson <gwilson@delphix.com>
Closes #10785
Closes #10934

Details

Provenance
George Wilson <george.wilson@delphix.com>Authored on Sep 25 2020, 8:09 PM
GitHub <noreply@github.com>Committed on Sep 25 2020, 8:09 PM
Parents
rGa5c77dc4d53e: zfs_log_write: simplify data copying code for WR_COPIED records
Branches
Unknown
Tags
Unknown

Event Timeline

GitHub <noreply@github.com> committed rGbd76bcb36dcd: zpool command complains about /etc/exports.d (authored by George Wilson <george.wilson@delphix.com>).Sep 25 2020, 8:09 PM