NFS as Client/Server
The protocol NFS was developed by SUN Microsystems and
is now de facto standard for distributed file access.
NFS does not require the movement of file copies across the network.
Accessibility: Potential access to all available drivers on the network
Remote computer is NFS server. The deamon nfsd
is a server on the side of the remote workstation.
Client makes mount to access to remote directories and
all remote files on the mounted system are accessible so as them were
reside on the local system.
To mount remote file system over NFS do
mount dbs:/export /my_dbs
Here, dbs is the name of the remote system,
export is the remote file system on the workstation dbs
and /my_dbs is the mount point. Mount point is the
somewhat directory on the local system.
Portability and Compatibility of the NFS
Portability: NFS uses the protocol XDR ( External Data Representation )
XDR provides machine independent data formats.
Compatibility: NFS uses of simple protocols ( UDP, RPC )
that enables to use it on the different operational environments.
NFS layered on UDP ( User Datagram Protocol ).
It makes access to remote system more fast and not so reliable as
against as NFS would be layered on TCP.
NFS uses RPC ( Remote Procedure Call )
Transparent access: Remote accsess should look the same as local access
at the use and application levels.
RPC is a facility that allows for the remote execution of procedures using a
format and calling mechanism similar to that used for local procedure calls.
Reliability and Perfomance of the NFS
The protocol NFS is independent of history.
Server does not remember previous operations with a file.
Client remembers - it is more reliable and more slow.
"Disconnected server" and "Slow server" is the same thing for the client.
Reasonable perfomance: File access should be 75% as fast as it would
be on a local disk drive. The extra 25% is a small price to pay for the
added flexibility that NFS provides.
To get some NFS statistics use the command nfsstat.
Crash recoverability: Rebooting of server does not require reboot of client
Client must be able to recover easily from NFS server crashes
Some simple security principles
If security is a major concern, do not use NFS !
NFS is to be used in environment where all users are trusted
Disabling NFS server exporting:
- delete /etc/dfs/dfstab
- stop nfsd deamon
- remove NFS deamon entries from boot
Do not export the /, /bin, /usr file systems
Export specific directories rather than full file systems
Mark the file system directory as read-only with the -o option
Shareable file systems
share - make local resource available
for mounting by remote systems
share [-F fstype] [ -o options] [-d ""] [resource]
/etc/dfs/dfstab - list of share commands to be executed at boot time
Examples,
1) share -F nfs -o rw=frank:dublin:freedom /opt/share
where frank, dublin and freedom are workstation names,
/opt/share is the file system enabled to access.
2) share -F nfs -o anon=110, ro=frank:dublin /data/temp
where "anon = 110" means to set uid ( 110 ) to be effective user ID
of unauthenticated users, if uid = -1, access is denied,
"ro" means read only access mode.
/etc/dfs/sharetab - shared file systems table
shareall - shares all resorces from the file /etc/dfs/dfstab
unshare - make a local resource unvailable for mounting
by the remote systems
unshareall - unshares all currently shareable file systems
[Home]
[Five UNIX Tips]
[Tip 1 - File system and UNIX shell]
[Tip 2 - User environment and multi processing]
[Tip 3 - UNIX windows]
[Tip 5 - More about file system]
[UNIX vendors, Home Pages, Workstations, FAQs, News Groups]
Maintained by Rafael Stekolshchik
Last updated: July 4, 1998
klivlend1@yahoo.com
This page hosted by
Get your own Free Home Page