NFS

Definitions

How does it work?

Review of OSI Model
 
Application Provides interfaces for apps to access network services
Presentation Defines format for network communication
Session Manages the dialog between two computers
Transport Solves transmission problems,  flow control, reliability
Network Addresses the package, determines best route
Data-link Converts data frames to bits, or bits to data frames
Physical Converts bits to signals, knows what signal to use on cable type

From the OSI Perspective:
 

Client / Server Mounting Protocol File Service Interface What happens to the open file while you are writing to it? File Locking

NFS Client Side

NFS Server Side

Trouble Shooting Problems NFS Security

Files:

What is host-based security?
An example of Linux host-based security

Rule of thumb NFS File access is based on UID, GID tcp_wrappers     How it works     Example configuration Automatic Mounting of Filesystems
/etc/fstab
automount

The /etc/fstab configuration file

LABEL=/          /             ext3    defaults    1 1
/dev/sdb6        /usr/bin      ext3    defaults    1 2
#/dev/sdb6       /mnt/ro       ext3    defaults    1 2
none            /dev/pts       devpts  gid=5,mode=620 0 0
none            /proc          proc    defaults    0 0
none            /dev/shm       tmpfs   defaults    0 0
LABEL=/var      /var           ext3    defaults    1 2
/dev/sdb5       swap           swap    pri=1,defaults 0 0
/dev/sda5       swap           swap    pri=1,defaults 0 0
/dev/sdb1       /home          ext3    usrquota    1 2
/dev/cdrom      /mnt/cdrom     iso9660 owner,kudzu,ro,nosuid 0 0
/dev/fd0        /mnt/floppy    auto    noauto,owner,kudzu,nosuid 0 0
gandalf:/var/ftp/pub/rh7.3  /mnt/gandalf   nfs  defaults  0 0

Settings for the Options Field in the /etc/fstab file

 
async Specifies that all reads and writes to the file system should be asynchronous, ie, buffered in memory to improve access speed.
auto Specifies that the file system should be automatically mounted at boot time or when the mount command is used with the -a option.
dev Designates the file system as a special device in the ./dev directory (block or character).
exec  Permits execution of binaries stored on file system.
noauto Can only be mounted explicitly, ie, the -a option will not cause the file system to  be mounted.
noexec Do not allow execution of any binaries on the mounted file system. Useful for a server's file system containing binaries for architectures other then its own.
nouser Only root can mount the file system.
ro Mount the file system read-only.
rw Mount the file system read-write.
suid Allows special user ID permissions to b used on this file system.
user Allow an ordinary user to mount the file system, ie, floppy or CDROM.
owner Owner is similar to user, with the restriction that the user must be the owner. e.g. for /dev/fd if a login script makes the console user owner of this device.
users Same as user option,  except any user can unmount the device.
defaults  Use default options: rw, suid, dev, exec, auto, nouser, and async.

Additional Points about the Options Field

Exercise: Tcpdump