MOUNT(2) UNIX Programmer's Manual MOUNT(2) NAME mount, umount - mount or remove file system SYNOPSIS mount(special, name, rwflag) char *special, *name; umount(special) char *special; DESCRIPTION _M_o_u_n_t announces to the system that a removable file system has been mounted on the block-structured special file _s_p_e_- _c_i_a_l; from now on, references to file _n_a_m_e will refer to the root file on the newly mounted file system. _S_p_e_c_i_a_l and _n_a_m_e are pointers to null-terminated strings containing the appropriate path names. _N_a_m_e must exist already. _N_a_m_e must be a directory (unless the root of the mounted file system is not a directory). Its old contents are inaccessible while the file system is mounted. The _r_w_f_l_a_g argument determines whether the file system can be written on; if it is 0 writing is allowed, if non-zero no writing is done. Physically write-protected and magnetic tape file systems must be mounted read-only or errors will occur when access times are updated, whether or not any explicit write is attempted. _U_m_o_u_n_t announces to the system that the _s_p_e_c_i_a_l file is no longer to contain a removable file system. The associated file reverts to its ordinary interpretation. ERRORS _M_o_u_n_t will fail if: [EPERM] The process's effective user ID is not the super-user. [ENODEV] _S_p_e_c_i_a_l does not exist. [ENOTBLK] _S_p_e_c_i_a_l is not a block device. [ENXIO] The major device number of _s_p_e_c_i_a_l is out of range (this indicates no device driver exists for the associated hardware). [EINVAL] The path name _n_a_m_e contains a non-ASCII byte. Printed 5/23/83 1 MOUNT(2) UNIX Programmer's Manual MOUNT(2) [ENOTDIR] A component of the path prefix in _n_a_m_e is not a directory. [EROFS] _N_a_m_e resides on a read-only file system. [EBUSY] _N_a_m_e is not a directory or another pro- cess currently holds a reference to it. [EBUSY] No space remains in the mount table. _U_m_o_u_n_t may fail with one of the following errors: [EPERM] The process's effective user ID is not the super-user. [ENODEV] _S_p_e_c_i_a_l does not exist. [ENOTBLK] _S_p_e_c_i_a_l is not a block device. [ENXIO] The major device number of _s_p_e_c_i_a_l is out of range (this indicates no device driver exists for the associated hardware). [EINVAL] The requested device is not in the mount table. [EBUSY] A process is holding a reference to a file located on the file system. SEE ALSO mount(8) ASSEMBLER (mount = 21.) sys mount; special; name; rwflag (umount = 22.) sys umount; special Printed 5/23/83 2