lofs man page on SmartOS

Man page or keyword search:  
man Server   16655 pages
apropos Keyword Search (all sections)
Output format
SmartOS logo
[printable version]

LOFS(7FS)							     LOFS(7FS)

NAME
       lofs - loopback virtual file system

SYNOPSIS
       #include <sys/param.h>
       #include <sys/mount.h>

       int mount (const char* dir, const char* virtual, int mflag, lofs, NULL, 0);

DESCRIPTION
       The  loopback file system device allows new, virtual file systems to be
       created, which provide access to existing files using  alternate	 path‐
       names.  Once the virtual file system is created, other file systems can
       be mounted within it, without affecting the original file system.  How‐
       ever,  file  systems  which  are subsequently mounted onto the original
       file system 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.

       virtual is the mount point for the virtual  file	 system.  dir  is  the
       pathname	 of  the  existing  file  system.  mflag  specifies  the mount
       options; the  MS_DATA bit in  mflag must be set. If the	MS_RDONLY  bit
       in   mflag  is  not  set, accesses to the loop back file system are the
       same as for the underlying file system. Otherwise, all accesses in  the
       loopback	 file system will be read-only. All other mount(2) options are
       inherited from the underlying file systems.

       A loopback mount of '/' onto /tmp/newroot allows the entire file system
       hierarchy  to  appear  as  if  it  were	duplicated under /tmp/newroot,
       including any file systems mounted from remote NFS servers.  All	 files
       would then be accessible either from a pathname relative to '/' or from
       a pathname relative to /tmp/newroot until such time as a file system is
       mounted in /tmp/newroot, or any of its subdirectories.

       Loopback	 mounts	 of  '/'  can  be  performed  in  conjunction with the
       chroot(2) system call, to provide a complete virtual file system	 to  a
       process or family of processes.

       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 (for	 exam‐
       ple, as an empty directory).

   Examples
       lofs file systems are mounted using:

	 mount -F lofs /tmp /mnt

SEE ALSO
       lofiadm(1M),   mount(1M),  chroot(2),  mount(2),	 sysfs(2),  vfstab(4),
       lofi(7D)

NOTES
       All access to entries in lofs mounted file systems map to their	under‐
       lying file system. If a mount point is made available in multiple loca‐
       tions via lofs and is busy in any of those  locations,  an  attempt  to
       mount  a	 file system at that mount point fails unless the overlay flag
       is specified. See mount(1M). Examples  of  a  mount  point  being  busy
       within  a  lofs	mount include having a file system mounted on it or it
       being a processes' current working directory.

WARNINGS
       Because of the potential for  confusing	users  and  applications,  you
       should  use  loopback  mounts  with  care.  A  loopback	mount entry in
       /etc/vfstab must be placed after the mount points of  both  directories
       it  depends  on.	 This is most easily accomplished by  making the loop‐
       back mount entry the last in /etc/vfstab.

				 Aug 31, 2009			     LOFS(7FS)
[top]

List of man pages available for SmartOS

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net