chroot.2
来自「<B>Digital的Unix操作系统VAX 4.2源码</B>」· 2 代码 · 共 76 行
2
76 行
.\" SCCSID: @(#)chroot.2 8.3 3/29/91.\" Last modified by Michaud 16-Sept-1986 1000..TH chroot 2.SH Namechroot \- change root directory.SH Syntax.nfchroot(\fIdirname\fP)char *\fIdirname;\fP.fi.SH Description.NXR "chroot system call".NXA "chdir system call" "chroot system call".NXR "root directory" "changing"The.I dirnameis the address of the pathname of a directory,terminated by a null byte.The.PN chrootsystem call causes this directoryto become the root directory (/)..PPFor a directory to become the root directory,a process must have execute (search) access to the directory..PPThis call is restricted to the superuser..SH Return ValuesUpon successful completion, a value of 0 is returned. Otherwise,a value of \-1 is returned and \fIerrno\fP is set to indicate an error..SH DiagnosticsThe.PN chrootsystem call fails and the root directory is unchanged under thefollowing conditions:.TP 15[ENOTDIR]A component of the \fIdirname\fP is not a directory..TP 15[ENAMETOOLONG]A component of a \fIdirname\fP exceeded 255 characters, oran entire \fIdirname\fP exceeded 1023 characters..TP 15[ENOENT]The \fIdirname\fP argument points to the name of a directory whichdoes not exist, or to an empty string and the environmentdefined is POSIX or SYSTEM_FIVE..TP 15[EFAULT]The.I dirname points outside the process's allocated address space..TP 15[ELOOP]Too many symbolic links were encountered in translatingthe pathname..TP 15[EIO]An I/O error occurred while reading from or writing to thefile system..TP 15[ESTALE]The file handle given in the argument is invalid. The file referred to by that file handle no longer exists or hasbeen revoked..TP[ETIMEDOUT]A connect request or remote file operation failed because the connected partydid not properly respond after a period of time that is dependent onthe communications protocol..TP 15[EPERM]The effective user ID is not that of superuser..SH See Alsochdir(2)
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?