Thursday, November 12, 2009

NFS Server

Package - nfs-utils
Service - portmap and nfs
Port No. - 111

Configuration Files
/etc/exports
/etc/hosts.allow
/etc/hosts.deny


Shared NFS directory is listed in /etc/exports,this file control the shared directory.

Example
#/etc/exports
/data/files *(ro,sync)
/home 192.168.1.0/24(rw,sync)
/data/test *.my-site.com(rw,sync)

/data/database 192.168.1.203/32(rw,sync)


showmount queries the mount daemon on a remote host for information
about the state of the NFS server on that machine.

Note:
  1. Only export directories beneath the / directory.
  2. Do not export a subdirectory of a directory that has already been exported. The exception being when the subdirectory is on a different physical device. Likewise, do not export the parent of a subdirectory unless it is on a separate device.
  3. Only export local filesystems.

Keep in mind that when you mount any filesystem on a directory, the original contents of the directory are ignored, or obscured, in favor of the files in the mounted filesystem. When the filesystem is unmounted, then the original files in the directory reappear unchanged.








No comments: