sudo apt-get install nfs-common nfs-kernel-service portmap
2. 修改 /etc/exports
/home/neo/qcroot *(rw,sync,no_root_squash,subtree_check)
3. 修改 /etc/hosts
127.0.0.1 localhost
192.168.0.66 NEO
192.168.0.100 TEST
4. 修改 /etc/hosts.allow
portmap : 192.168.0.66
ALL:ALL
5. 重新啟動程式
/etc/init.d/portmap start
/etc/init.d/nfs-common start
/etc/init.d/nfs-kernel-server start
6. 檢查安裝情況
showmount -e
Client 端
mount -t nfs -o rw,nolock 192.168.0.66:/home/neo/qcroot /qcroot
PS: 如果client端並沒有執行portmap, 則mount時要加入nolock option, 否則會有 Input/output error
沒有留言:
張貼留言