.\" $NetBSD: mount_9p.8,v 1.17 2022/02/11 14:10:12 uwe Exp $ .\" .\" Copyright (c) 2007 Antti Kantee. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .Dd February 10, 2022 .Dt MOUNT_9P 8 .Os .Sh NAME .Nm mount_9p .Nd mount a file server using the 9P resource sharing protocol .Sh SYNOPSIS .Nm .Op Fl 46Csu .Op Fl o Ar options .Op Fl p Ar port .Oo Ar user Ns Li \&@ Oc Ns Ar host Ns Op Li \&: Ns Ar path .Ar mount_point .Nm .Fl c .Op Fl Csu .Op Fl o Ar options .Ar device .Ar mount_point .Sh DESCRIPTION The .Nm program is used to mount a file hierarchy served with the Plan 9 resource sharing protocol 9P. After the file system is mounted, the files on the remote .Ar host will be accessed using the credentials of the user named .Ar user and whatever UID the user happens to have on the remote server. If .Ar path is supplied, it is used as the mount rootpath on the remote host. .Ar path must be an absolute path. .Pp The host name may be optionally enclosed in square brackets. This is required when using numeric IPv6 addresses as they contain colons as part of their syntax. .Pp The .Fl c option enables to mount a file system exported by a VM host through a character device file .Ar device backed by the .Xr vio9p 4 driver. See .Xr vio9p 4 for more information. .Pp The following options are available: .Bl -tag -width "Fl o Ar options" .It Fl 4 Forces .Nm to use IPv4 addresses only. .It Fl 6 Forces .Nm to use IPv6 addresses only. .It Fl C Permit the kernel to cache pathname components. By default every time the kernel does a lookup for a component name, the file server will be consulted. .It Fl c Interpret .Ar special as a device name. See .Xr vio9p 4 . .It Fl o Ar options Mount options. See documentation for the .Fl o option to .Xr mount 8 . .It Fl p Ar port Use the specified TCP port. By default .Nm uses port 564 .Li ( 9pfs ) . Another useful port is 6666 .Li ( styx ) , used by Inferno operating system. .It Fl s Run in the foreground. Useful for debugging. .It Fl u Use 9P2000.u protocol that includes extensions to better support Unix environments. .El .Sh SEE ALSO .Xr puffs 3 , .Xr puffs 4 , .Xr vio9p 4 , .Xr mount 8 .Rs .%T 9P: The Simple Distributed File System from Bell Labs .%U http://9p.cat-v.org/ .Re .Rs .%T RFC and standards documents relating the 9P protocol .%U http://ericvh.github.io/9p-rfc/ .Re .Sh HISTORY The .Nm utility first appeared in .Nx 5.0 . .Pp Experimental 9P2000.u support appeared in .Nx 9.0 . .Pp The .Xr vio9p 4 support appeared in .Nx 10.0 . .Sh CAVEATS Authentication is not supported. .Pp Permissions are not handled well. .Pp Error code handling is missing for 9P2000. .Pp 9P2000.u support doesn't use extension fields.