mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 18:40:43 +03:00
Change default to overlay=on
Filesystems allow overlay mounts by default on FreeBSD and Linux. Respect the native convention by switching the default to overlay=on, while retaining the option to turn the property off for compatibility with other operating systems' conventions. Update documentation and tests accordingly. Reviewed-by: Richard Laager <rlaager@wiktel.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Ryan Moeller <ryan@iXsystems.com> Closes #10030
This commit is contained in:
@@ -474,8 +474,8 @@ zfs_mount_at(zfs_handle_t *zhp, const char *options, int flags,
|
||||
}
|
||||
|
||||
/*
|
||||
* Overlay mounts are disabled by default but may be enabled
|
||||
* via the 'overlay' property or the 'zfs mount -O' option.
|
||||
* Overlay mounts are enabled by default but may be disabled
|
||||
* via the 'overlay' property. The -O flag remains for compatibility.
|
||||
*/
|
||||
if (!(flags & MS_OVERLAY)) {
|
||||
if (zfs_prop_get(zhp, ZFS_PROP_OVERLAY, overlay,
|
||||
@@ -489,7 +489,7 @@ zfs_mount_at(zfs_handle_t *zhp, const char *options, int flags,
|
||||
/*
|
||||
* Determine if the mountpoint is empty. If so, refuse to perform the
|
||||
* mount. We don't perform this check if 'remount' is
|
||||
* specified or if overlay option(-O) is given
|
||||
* specified or if overlay option (-O) is given
|
||||
*/
|
||||
if ((flags & MS_OVERLAY) == 0 && !remount &&
|
||||
!dir_is_empty(mountpoint)) {
|
||||
|
||||
Reference in New Issue
Block a user