MNT(3) MNT(3) NAME mnt - attach to 9P servers SYNOPSIS #M DESCRIPTION The mount driver is used by the mount system call (but not bind; see bind(2)) to connect the name space of a process to the service provided by a 9P server over a communications channel. After the mount, system calls involving files in that portion of the name space will be converted by the mount driver into the appropriate 9P messages to the server. The mount system call issues an auth(5) message to the server to validate the user and an attach(5) message to identify the user of the connection. Each distinct user of a connection must mount it separately; the mount driver mul- tiplexes the access of the various users and their processes to the service. File-oriented system calls are converted by the kernel into messages in the 9P protocol. Within the kernel, 9P is implemented by procedure calls to the various kernel device drivers. The mount driver translates these procedure calls into remote procedure calls to be transmitted as messages over the communication channel to the server. Each message is implemented by a write of the corresponding protocol mes- sage to the server channel followed by a read on the server channel to get the reply. Errors in the reply message are turned into system call error returns. A read(2) or write system call on a file implemented by the mount driver may be translated into more than one message, since there is a maximum data size for a 9P message. The system call will return when the specified number of bytes have been transferred or a short reply is returned. The string `#M' is an illegal file name, so this device can only be accessed directly by the kernel. BUGS It is not possible to mount a service through the mount driver across a network. As a result the window command will not work from the CPU server since it cannot mount the srv entry for 8½. SEE ALSO bind(2) Page 1 Plan 9 (printed 11/18/24)