你先要在192.168.1.100上开启NFS服务并编辑/etc/exports文件:
chkconfig --level 35 nfs on
service nfs start
vi /etc/exports,加入:
/tmp 192.168.1.200(rw,sync,no_root_squash)
然后,在192.168.1.200(如果你现在登录在192.168.1.100,当然要ssh登录到192.168.1.200,并su成root)运行:
mkdir /tmp
chmod 777 -R /tmp
mount 192.168.1.100:/tmp /tmp
就可以了。
把mount这行加入到/etc/rc.local,开机就会自动挂载了。
温馨提示:答案为网友推荐,仅供参考