NAME
     mount, umount - mount and unmount file systems

SYNOPSIS
     /usr/etc/mount [ -p ]
     /usr/etc/mount -a [ fnv ] [ -t type ]
     /usr/etc/mount [ -fnrv ] [ -t type ] [ -o options ] filesys-
     tem directory
     /usr/etc/mount [ -vfn ] [ -o options ] filesystem  |  direc-
     tory
     /usr/etc/mount -d [ fnvr ] [ -o  options  ]  RFS-resource  |
     directory

     /usr/etc/umount [ -t type ] [ -h host ]
     /usr/etc/umount -a [ v ]
     /usr/etc/umount [ -v ] filesystem|directory  ...
     /usr/etc/umount [ -d ] RFS-resource | directory

DESCRIPTION
     mount attaches a named filesystem to the file system hierar-
     chy  at  the pathname location directory, which must already
     exist.  If directory has any contents  prior  to  the  mount
     operation,  these remain hidden until the filesystem is once
     again   unmounted.    If   filesystem   is   of   the   form
     host:pathname,  it is assumed to be an NFS file system (type
     nfs).

     umount unmounts a currently mounted file system,  which  can
     be specified either as a directory or a filesystem.

     mount and umount maintain a table of mounted file systems in
     /etc/mtab,  described  in  fstab(5).   If invoked without an
     argument, mount displays the  contents  of  this  table.  If
     invoked  with  either  a filesystem or directory only, mount
     searches the file  /etc/fstab  for  a  matching  entry,  and
     mounts  the file system indicated in that entry on the indi-
     cated directory.

     mount also allows the creation of new, virtual file  systems
     using loopback mounts.  Loopback file systems provide access
     to existing files using alternate pathnames.  Once a virtual
     file  system  is  created, other file systems can be mounted
     within it without affecting the original file system.   File
     systems that are subsequently mounted onto the original file
     system, however, are visible to  the  virtual  file  system,
     unless or until the corresponding mount point in the virtual
     file system is covered by a file system mounted there.

     Recursive traversal of loopback mount points is not allowed;
     after   the   loopback   mount  of  /tmp/newroot,  the  file
     /tmp/newroot/tmp/newroot does not contain yet  another  file
     system  hierarchy.   Rather, it appears just as /tmp/newroot
     did before the loopback mount  was  performed  (say,  as  an
     empty directory).

     The standard RC files first perform  4.2  mounts,  then  nfs
     mounts,  during  booting.  On Sun386i systems, lo (loopback)
     mounts are performed  just  after  4.2  mounts.   /etc/fstab
     files  depending on alternate mount orders at boot time will
     fail  to  work  as   expected.    Manual   modification   of
     /etc/rc.local will be needed to make such mount orders work.

     See lofs(4S) and fstab(5) for more information and  WARNINGS
     about loopback mounts.

OPTIONS
  mount
     -p   Print the list of mounted  file  systems  in  a  format
          suitable for use in /etc/fstab.

     -a   All.  Attempt to mount all the file  systems  described
          in  /etc/fstab.   If  a type argument is specified with
          -t, mount all file systems of  that  type.   Using  -a,
          mount  builds  a  dependency  tree  of  mount points in
          /etc/fstab.  mount will correctly mount these file sys-
          tems  regardless  of  their order in /etc/fstab (except
          loopback mounts; see WARNINGS below).

     -f   Fake an /etc/mtab entry, but do not actually mount  any
          file systems.

     -n   Mount the  file  system  without  making  an  entry  in
          /etc/mtab.

     -v   Verbose.  Display a message indicating each file system
          being mounted.

     -t type
          Specify a file system type.   The  accepted  types  are
          4.2,  nfs,  rfs, lo, hsfs, and tmp.  See fstab(5) for a
          description of 4.2, hsfs, and nfs; see lofs(4S)  for  a
          description  of  lo; and see tmpfs(4) for a description
          of tmp.  See  System  and  Network  Administration  for
          details on rfs.

     -r   Mount the specified file system read-only, even if  the
          entry  in /etc/fstab specifies that it is to be mounted
          read-write.

          Physically write-protected and magnetic-tape file  sys-
          tems  must be mounted read-only. Otherwise errors occur
          when the system attempts to update access  times,  even
          if no write operation is attempted.

     -d   Mount an RFS file system. This option provides compati-
          bility  with  the  System  V,  Release 3 syntax for RFS
          mounts. Alternatively, the equivalent  Sun  syntax,  -t
          rfs, may be used.

     -o options
          Specify file system options, a comma-separated list  of
          words  from the list below.  Some options are valid for
          all file system types, while others apply to a specific
          type only.

          options valid on all file systems:

               rw|ro         Read/write or read-only.
               suid|nosuid   Setuid execution allowed  or  disal-
                             lowed.
               grpid         Create files with BSD semantics  for
                             the  propagation  of  the  group ID.
                             Under this option, files inherit the
                             GID  of  the directory in which they
                             are  created,  regardless   of   the
                             directory's set-GID bit.
               noauto        Do not mount this file  system  that
                             is  currently mounted read-only.  If
                             the file  system  is  not  currently
                             mounted, an error results.
               remount       If  the  file  system  is  currently
                             mounted,   and   if   the  entry  in
                             /etc/fstab specifies that it  is  to
                             be  mounted  read-write  or  rw  was
                             specified   along   with    remount,
                             remount  the  file  system making it
                             read-write.    If   the   entry   in
                             /etc/fstab  specifies  that it is to
                             be mounted read-only and rw was  not
                             specified,  the  file  system is not
                             remounted.  If the  file  system  is
                             currently mounted read-write, speci-
                             fying ro along with remount  results
                             in  an error.  If the file system is
                             not  currently  mounted,  an   error
                             results.

               The default is `rw,suid'.

          options specific to 4.2 file systems:

               quota|noquota  Usage limits are enforced,  or  are
                              not   enforced.    The  default  is
                              noquota.


          options specific to nfs (NFS) file systems:

               bg|fg         If the first attempt fails, retry in
                             the  background,  or,  in  the fore-
                             ground.
               noquota       Prevent   quota(1)   from   checking
                             whether  the  user  is over quota on
                             this file system; if the file system
                             has  quotas  enabled  on the server,
                             quotas will  still  be  checked  for
                             operations on this file system.
               retry=n       The number of  times  to  retry  the
                             mount operation.
               rsize=n       Set the read buffer size to n bytes.
               wsize=n       Set  the  write  buffer  size  to  n
                             bytes.
               timeo=n       Set the NFS timeout to n tenths of a
                             second.
               retrans=n     The number of NFS retransmissions.
               port=n        The server IP port number.
               soft|hard     Return an error if the  server  does
                             not  respond,  or continue the retry
                             request until the server responds.
               intr          Allow keyboard  interrupts  on  hard
                             mounts.
               secure        Use a more secure protocol  for  NFS
                             transactions.
               posix         Request POSIX.1  semantics  for  the
                             file  system.  Requires a mount ver-
                             sion 2 mountd(8C) on the server.
               acregmin=n    Hold cached attributes for at  least
                             n seconds after file modification.
               acregmax=n    Hold cached attributes for  no  more
                             than  n seconds after file modifica-
                             tion.
               acdirmin=n    Hold cached attributes for at  least
                             n seconds after directory update.
               acdirmax=n    Hold cached attributes for  no  more
                             than   n   seconds  after  directory
                             update.
               actimeo=n     Set min and max  times  for  regular
                             files and directories to n seconds.
               nocto         Suppress fresh attributes when open-
                             ing a file.
               noac          Suppress attribute and name (lookup)
                             caching.

               Regular defaults are:
                    fg,retry=10000,timeo=7,retrans=3,port=NFS_PORT,hard,\
                    acregmin=3,acregmax=60,acdirmin=30,acdirmax=60


               actimeo has no default; it sets  acregmin,  acreg-
               max, acdirmin and acdirmax

               Defaults for rsize and wsize are set internally by
               the system kernel.

          options specific to rfs (RFS) file systems:

               bg|fg         If the first attempt fails, retry in
                             the  background,  or,  in  the fore-
                             ground.
               retry=n       The number of  times  to  retry  the
                             mount operation.

               Defaults are the same as for NFS.

          options specific to hsfs (HSFS) file systems:

               norrip        Disable  processing  of  Rock  Ridge
                             extensions for the file system.

  umount
     -h host
          Unmount all file systems listed in /etc/mtab  that  are
          remote-mounted from host.

     -t type
          Unmount all file systems listed in /etc/mtab  that  are
          of a given type.

     -a   Unmount all file systems currently mounted  (as  listed
          in /etc/mtab).

     -v   Verbose.  Display a message indicating each file system
          being unmounted.

     -d   Unmount an RFS file system.  This option provides  com-
          patibility  with  the  System  V,  Release 3 syntax for
          unmounting an RFS file system.

NFS FILESYSTEMS
  Background vs. Foreground
     Filesystems mounted with the bg option indicate  that  mount
     is  to  retry in the background if the server's mount daemon
     (mountd(8C)) does not respond.  mount retries the request up
     to the count specified in the retry=n option.  Once the file
     system is mounted, each NFS request made in the kernel waits
     timeo=n  tenths  of a second for a response.  If no response
     arrives, the time-out is multiplied by 2 and the request  is
     retransmitted.   When  the  number  of  retransmissions  has
     reached the number specified in the retrans=n option, a file
     system  mounted with the soft option returns an error on the
     request; one mounted with the hard option prints  a  warning
     message and continues to retry the request.

  Read-Write vs. Read-Only
     File systems that are mounted rw (read-write) should use the
     hard option.

  Interrupting Processes With Pending NFS Requests
     The intr option allows keyboard interrupts to kill a process
     that  is hung while waiting for a response on a hard-mounted
     file system.

  Quotas
     Quota checking on NFS  file  systems  is  performed  by  the
     server,  not  the  client;  if the file system has the quota
     option on the server, quota checking is performed  for  both
     local  requests  and  NFS  requests.   When  a user logs in,
     login(1) runs the quota(1) program to check whether the user
     is  over  their  quota on any of the file systems mounted on
     the machine.  This check is performed for NFS  file  systems
     by an RPC call to the rquotad(8C) server on the machine from
     which the  file  system  is  mounted.   This  can  be  time-
     consuming, especially if the remote machine is down.  If the
     noquota option is specified for an NFS  file  system,  quota
     will  not check whether the user is over their quota on that
     file system, which can speed up the process of  logging  in.
     This  does not disable quota checking for operations on that
     file system; it merely disables reporting whether  the  user
     is over quota on that file system.

  Secure Filesystems
     The secure option must  be  given  if  the  server  requires
     secure mounting for the file system.

  File Attributes
     The attribute cache retains file attributes on  the  client.
     Attributes  for a file are assigned a time to be flushed. If
     the file is modified before the flush time, then  the  flush
     time  is  extended  by  the time since the last modification
     (under the assumption that files that changed  recently  are
     likely  to  change  soon).   There  is a minimum and maximum
     flush time extension for regular files and for  directories.
     Setting  actimeo=n  extends flush time by n seconds for both
     regular files and directories.

SYSTEM V COMPATIBILITY
  System V File-Creation Semantics
     Ordinarily, when a file is created its GID  is  set  to  the
     effective  GID of the calling process.  This behavior may be
     overridden on a per-directory basis, by setting the  set-GID
     bit of the parent directory; in this case, the GID is set to
     the  GID  of  the  parent  directory   (see   open(2V)   and
     mkdir(2V)).   Files created on file systems that are mounted
     with the grpid option will obey BSD semantics; that is,  the
     GID  is  unconditionally  inherited  from that of the parent
     directory.

EXAMPLES
          To mount a local disk:
               mount /dev/xy0g /usr
          To fake an entry for nd root:
               mount -ft 4.2 /dev/nd0 /
          To mount all 4.2 file systems:
               mount -at 4.2
          To mount a remote file system:
               mount -t nfs serv:/usr/src /usr/src
          To mount a remote file system:
               mount serv:/usr/src /usr/src
          To hard mount a remote file system:
               mount -o hard serv:/usr/src /usr/src
          ground on failure:
          To mount an RFS remote file system, retrying  in  the  back-
               mount -d -o bg SRC /usr/src
          To mount an RFS remote file system read-only:
               mount -t rfs -r SRC /usr/src
          To save current mount state:
               mount -p > /etc/fstab
               Note: this is not  recommended  when  running  the
               automounter, see automount(8).
          To loopback mount file systems:
               mount -t lo /export/tmp/localhost /tmp
               mount -t lo /export/var/localhost /var lo
               mount -t lo /export/cluster/sun386.sunos4.0.1 /usr/cluster
               mount -t lo /export/local/sun386 /usr/local

FILES
     /etc/mtab           table of mounted file systems
     /etc/fstab          table of file systems mounted at boot

WARNINGS
     mount does  not  understand  the  mount  order  dependencies
     involved  in  loopback  mounting.   Loopback  mounts  may be
     dependent on two mounts having  been  previously  performed,
     while nfs and 4.2 mounts are dependent only on a single pre-
     vious mount.  As a rule of thumb, place loopback  mounts  at
     the end of the /etc/fstab file.  See lofs(4S) for a complete
     description.

SEE ALSO
     mkdir(2V),  mount(2V),  open(2V),   unmount(2V),   lofs(4S),
     fstab(5), mtab(5), automount(8), mountd(8C), nfsd(8)

BUGS

     Mounting file systems full of garbage crashes the system.

     If the directory on which a file system is to be mounted  is
     a symbolic link, the file system is mounted on the directory
     to which the symbolic link refers, rather than being mounted
     on top of the symbolic link itself.