diff options
author | Ned Bass <[email protected]> | 2015-03-26 12:10:26 -0700 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2015-03-27 14:46:58 -0700 |
commit | 9540be9b23fd6f8b5bf7d81853c251010d9b7205 (patch) | |
tree | e0391f316fad41e8d86180be53914db2f7be4cae /cmd | |
parent | 95a6990d9a77a56eb97b76f2880f95f0f42f4fe0 (diff) |
zpool import should honor overlay property
Make the 'zpool import' command honor the overlay property to allow
filesystems to be mounted on a non-empty directory. As it stands now
this property is only checked by the 'zfs mount' command. Move the
check into 'zfs_mount()` in libzpool so the property is honored for all
callers.
Signed-off-by: Ned Bass <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes #3227
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/zfs/zfs_main.c | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/cmd/zfs/zfs_main.c b/cmd/zfs/zfs_main.c index 83f02666d..84073435e 100644 --- a/cmd/zfs/zfs_main.c +++ b/cmd/zfs/zfs_main.c @@ -5641,7 +5641,6 @@ share_mount_one(zfs_handle_t *zhp, int op, int flags, char *protocol, char mountpoint[ZFS_MAXPROPLEN]; char shareopts[ZFS_MAXPROPLEN]; char smbshareopts[ZFS_MAXPROPLEN]; - char overlay[ZFS_MAXPROPLEN]; const char *cmdname = op == OP_SHARE ? "share" : "mount"; struct mnttab mnt; uint64_t zoned, canmount; @@ -5749,19 +5748,6 @@ share_mount_one(zfs_handle_t *zhp, int op, int flags, char *protocol, } /* - * Overlay mounts are disabled by default but may be enabled - * via the 'overlay' property or the 'zfs mount -O' option. - */ - if (!(flags & MS_OVERLAY)) { - if (zfs_prop_get(zhp, ZFS_PROP_OVERLAY, overlay, - sizeof (overlay), NULL, NULL, 0, B_FALSE) == 0) { - if (strcmp(overlay, "on") == 0) { - flags |= MS_OVERLAY; - } - } - } - - /* * At this point, we have verified that the mountpoint and/or * shareopts are appropriate for auto management. If the * filesystem is already mounted or shared, return (failing |