Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

ffm(4) [osf1 man page]

ffm(4)							     Kernel Interfaces Manual							    ffm(4)

ffm - File-on-File Mounting File System STANDARDS
Interfaces documented on this reference page conform to industry standards as follows: fattach(): XSH4.2 fdetach(): XSH4.2 Refer to standards(5) for more information about industry standards and their associated tags. DESCRIPTION
The File-on-File Mounting (FFM) file system allows regular files, character device special files, or block device special files to be mounted on regular files or directories. The ffm file system is used with the System V Release 4-compatible library functions fattach(3) and detach(3) to enable a user process to have one file descriptor pointing to the data associated with a named file and a named STREAM. When one name is active, the other name is invisible. For example, a user application mounts a file descriptor from a file named a_file on a file that is named b_file. The file descriptor of file a_file is accessible by two names, a_file and b_file. However, when the user application attempts to open either file, only the file descriptor for a_file is returned: the file descriptor for b_file is invisible while a_file is mounted over it. The fattach(3) function mounts a file over another; the fdetach(3) function removes the association so the underlying file can be accessed. The user process can also mount a regular file over a regular file in order for it to be a clone of the underlying file. [Do not confuse this clone with an AdvFS clone fileset.] In this case, the clone file is a character device special file that is associated with a device driver that handles such files. As a result, a user can specify one clone entry and then open this device multiple times. Each time the device is opened, a new vnode is obtained but exactly the same device behavoir is also obtained: the behavior is cloned. That mount occurs if the -o clone option is used in the mount command or as an element of a ffm line in the /etc/fstab file. In this case, there are two files with identical contents, separate names, and separate file descriptors. EXAMPLES
The following example shows an ffm mount of a_file on b_file. If the du command were executed, its display would show a_file in the file system column and b_file in the Mounted on column: # mount -t ffm a_file b_file The following example shows an ffm mount of a_file on b_file, with the mount -o clone option specifying that a_file is a clone of b_file. # mount -t ffm -o clone a_file b_file RESTRICTIONS
The user process must be the root user or must be the owner of the files and must have write permissions for the files. [Tru64 UNIX] Before you can use the ffm file system, you must configure the kernel option FFM_FS into the kernel. See System Administra- tion for information about configuring the kernel. RELATED INFORMATION
Commands: fdetach(8), mount(8) Functions: fattach(3), fdetach(3), isastream(3), chmod(2), mount(2) Interfaces: streamio(7) Files: fstab(4) Standards: standards(5) delim off ffm(4)

Check Out this Related Man Page

fattach(3C)                                                Standard C Library Functions                                                fattach(3C)

fattach - attach a STREAMS- or doors-based file descriptor to an object in the file system name space SYNOPSIS
#include <stropts.h> int fattach(int fildes, const char *path); DESCRIPTION
The fattach() function attaches a STREAMS- or doors-based file descriptor to an object in the file system name space, effectively associat- ing a name with fildes. The fildes argument must be a valid open file descriptor representing a STREAMS or doors file. The path argument is a path name of an existing object and the user must have appropriate privileges or be the owner of the file and have write permissions. All subsequent operations on path will operate on the STREAMS or doors file until the STREAMS or doors file is detached from the node. The fildes argument can be attached to more than one path, that is, a stream or door can have several names associated with it. The attributes of the named stream or door (see stat(2)), are initialized as follows: the permissions, user ID, group ID, and times are set to those of path, the number of links is set to 1, and the size and device identifier are set to those of the streams or doors device asso- ciated with fildes. If any attributes of the named stream or door are subsequently changed (for example, chmod(2)), the attributes of the underlying object are not affected. RETURN VALUES
Upon successful completion, fattach() returns 0. Otherwise it returns -1 and sets errno to indicate an error. ERRORS
The fattach() function will fail if: EACCES The user is the owner of path but does not have write permissions on path or fildes is locked. EBADF The fildes argument is not a valid open file descriptor. EBUSY The path argument is currently a mount point or has a STREAMS or doors file descriptor attached to it. EINVAL The path argument is a file in a remotely mounted directory. EINVAL The fildes argument does not represent a STREAMS or doors file. ELOOP Too many symbolic links were encountered in translating path. ENAMETOOLONG The size of path exceeds {PATH_MAX}, or the component of a path name is longer than {NAME_MAX} while {_POSIX_NO_TRUNC} is in effect. ENOENT The path argument does not exist. ENOTDIR A component of a path prefix is not a directory. EPERM The effective user ID is not the owner of path or a user with the appropriate privileges. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Interface Stability |Standard | +-----------------------------+-----------------------------+ |MT-Level |MT-Safe | +-----------------------------+-----------------------------+ SEE ALSO
fdetach(1M), chmod(2), mount(2), stat(2), door_create(3DOOR), fdetach(3C), isastream(3C), attributes(5), standards(5), streamio(7I) STREAMS Programming Guide SunOS 5.10 24 Jul 2002 fattach(3C)
Man Page