📄 symlink.2
字号:
.\" SCCSID: @(#)symlink.2 8.1 9/11/90.TH symlink 2.SH Namesymlink \- make symbolic link to a file.SH Syntax.nf.ft Bsymlink(name1, name2)char *name1, *name2;.fi.ft R.SH Description.NXR "symlink system call".NXA "symlink system call" "readlink system call".NXA "symlink system call" "stat system call".NXR "file" "creating symbolic link to"A symbolic link.I name2is created to.IR name1(\fIname2\fP is the name of thefile created, \fIname1\fP is the stringused in creating the symbolic link).Either name can be an arbitrary path name. The files need notbe on the same file system..SH Return ValuesUpon successful completion, a zero (0) value is returned.If an error occurs, the error code is stored in \fIerrno\fP,and a \-1 value is returned..SH Diagnostics.NXR "symlink system call" "diagnostics"The symbolic link is made, unless one or more of thefollowing are true:.TP 15[ENOTDIR]A component of the \fIname2\fP prefix is not a directory..TP 15[EEXIST]The\fIname2\fP already exists..TP 15[EACCES]A component of the \fIname2\fP path prefix denies search permission..TP 15[EROFS]The file \fIname2\fP would reside on a read-only file system..TP 15[EFAULT]The.I name1or.I name2points outside the process's allocated address space..TP 15[ELOOP]Too many symbolic links were encountered in translating the pathname..TP 15[ENAMETOOLONG]A component of either pathname exceeded MAXNAMELEN characters, orthe entire length of either pathname exceeded MAXPATHNAME characters..TP 15[ENOENT]The named file does not exist..TP 15[EIO]An I/O error occurred while making the directory entry for.IR name2 ,or allocating the inode for.IR name2 ,or writing out the link contents of.IR name2 ..TP 15[ENOSPC]The directory in which the entry for the new symbolic linkis being placed cannot be extended, because there is no space lefton the file system containing the directory..TP 15[ENOSPC]The new symbolic link cannot be created, because there is nospace left on the file system that will contain thesymbolic link..TP 15[ENOSPC]There are no free inodes on the file system on which the symboliclink is being created..TP 15[EDQUOT]The directory in which the entry for the new symbolic linkis being placed cannot be extended because the user's quotaof disk blocks on the file system containing thedirectory has been exhausted..TP 15[EDQUOT]The new symbolic link cannot be created because the user'squota of disk blocks on the file system that will containthe symbolic link has been exhausted..TP 15[EDQUOT]The user's quota of inodes on the file system on whichthe user's symbolic link is being created has been exhausted..TP 15[EIO]An I/O error occurred while making the directory entry or allocatingthe inode..TP[ETIMEDOUT]A connect request or remote file operation failed,because the connected partydid not properly respond after a periodof time that is dependent on the communications protocol..SH See Alsoln(1), link(2), readlink(2), stat(2), unlink(2)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -