2013年4月21日 星期日

NFS

NFS user permissions are based on user ID (UID)
a user's access to files is determined by his/her membership of groups on the client, not on the server

Server Side

Packages

nfs-kernel-server
nfs-common
rpcbind

Server Install


apt-get install nfs-kernel-server


NFS Config

Config NFS exports so clients can mount the NFS drive

/etc/export

/home/ 192.168.100.0/24(rw,sync)

tips: Reload export config without restart NFS server

exportfs -a

restart services


/etc/init.d/rpcbind restart
/etc/init.d/nfs-kernel-server restart

Check local NFS config

showmount -e localhost

Client Side

Using autofs to mount NFS drive automatically

apt-get install autofs

File /etc/auto.master

/nfs /etc/auto.nfs

File /etc/auto.nfs

home -rw,fg,soft [IP of NFS server]:/[directory]



Mount with command manually

# mount -t nfs -o proto=tcp,port=2049 nfs-server:/ /mnt

Utililies

showmount


沒有留言:

張貼留言