diff options
| author | Michael Kerrisk <mtk.manpages@gmail.com> | 2019-07-30 12:37:26 +0200 |
|---|---|---|
| committer | Michael Kerrisk <mtk.manpages@gmail.com> | 2019-09-23 13:11:19 +0200 |
| commit | b647c4c93a4fb4c21617d8dbb705d9ab14a8d6e5 (patch) | |
| tree | 4883e00a13df4262a3fb6436e8a6ffb2fe8e85ca | |
| parent | 071505e9fbf45964db8a04b4fd10abe2a6e92749 (diff) | |
| download | man-pages-b647c4c93a4fb4c21617d8dbb705d9ab14a8d6e5.tar.gz | |
pivot_root.2: Add some more detail to the remaining EBUSY error
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
| -rw-r--r-- | man2/pivot_root.2 | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/man2/pivot_root.2 b/man2/pivot_root.2 index ebbd31f378..3e16b430e9 100644 --- a/man2/pivot_root.2 +++ b/man2/pivot_root.2 @@ -115,7 +115,28 @@ may fail with any of the same errors as Additionally, it may fail with the following errors: .TP .B EBUSY -\fInew_root\fP or \fIput_old\fP are on the current root filesystem. +.\" Reconfirmed that the following error occurs on Linux 5.0 by +.\" specifying 'new_root' as "/rootfs" and 'put_old' as +.\" "/rootfs/oldrootfs", and *not* bind mounting "/rootfs" on top of +.\" itself. Of course, this is an odd situation, since a later check +.\" in the kernel code will in any case yield EINVAL if 'new_root' is +.\" not a mount point. However, when the system call was first added, +.\" 'new_root' was not required to be a mount point. So, this this +.\" error is nowadays probably just the result of crufty accumulation. +.\" This error can also occur if we bind mount "/" on top of itself +.\" and try to specify "/" as the 'new' (again, an odd situation). So, +.\" the EBUSY check in the kernel does still seem necessary to prevent +.\" that case. Furthermore, the "or put_old" piece is probably +.\" redundant text (although the check is in the kernel), since, +.\" in another check, 'put_old' is required to be under 'new_root'. +.I new_root +or +.I put_old +is on the current root filesystem. +(This error covers the pathological case where +.I new_root +is +.IR """/""" .) .TP .B EINVAL .I new_root |
