diff options
author | Tim Chase <[email protected]> | 2013-11-06 23:55:18 -0600 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2013-11-08 10:45:14 -0800 |
commit | fd4f76160cb34539f875781fe7f2dea4b937ace5 (patch) | |
tree | 8fa4db23f72a58b049f53973f839a28793e2828e /lib/libspl/include | |
parent | b1d13a60d12a7df0f2e1bed6405529790213a6cb (diff) |
Handle concurrent snapshot automounts failing due to EBUSY.
In the current snapshot automount implementation, it is possible for
multiple mounts to attempted concurrently. Only one of the mounts will
succeed and the other will fail. The failed mounts will cause an EREMOTE
to be propagated back to the application.
This commit works around the problem by adding a new exit status,
MOUNT_BUSY to the mount.zfs program which is used when the underlying
mount(2) call returns EBUSY. The zfs code detects this condition and
treats it as if the mount had succeeded.
Signed-off-by: Brian Behlendorf <[email protected]>
Closes #1819
Diffstat (limited to 'lib/libspl/include')
-rw-r--r-- | lib/libspl/include/sys/mntent.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/libspl/include/sys/mntent.h b/lib/libspl/include/sys/mntent.h index 8fad65b56..736c3f866 100644 --- a/lib/libspl/include/sys/mntent.h +++ b/lib/libspl/include/sys/mntent.h @@ -39,6 +39,7 @@ #define MOUNT_FILEIO 0x10 /* Error updating/locking /etc/mtab */ #define MOUNT_FAIL 0x20 /* Mount failed */ #define MOUNT_SOMEOK 0x40 /* At least on mount succeeded */ +#define MOUNT_BUSY 0x80 /* Mount failed due to EBUSY */ #define MNTOPT_ASYNC "async" /* all I/O is asynchronous */ #define MNTOPT_ATIME "atime" /* update atime for files */ |