linux搭建nfs服务器

1. 安装:sudo yum install nfs  rpcbind

2. 配置:vim /etc/exports

/home/work/nfs 10.101.38.151(rw,no_all_squash,no_root_squash)

注意:出现“mount.nfs: access denied by server while mounting”,可能是“no_root_squash”选项没有添加

3. 启动服务:

sudo service rpcbind start

sudo service nfs start

sudo exportfs

注意:出现nfs启动失败的异常可能是rpc服务没有起来或者已经起来但是需要重启;不要忘记exportfs

4. 客户端查看服务器端可挂载点:

showmount -e 10.95.112.179

5. 客户端挂载:

sudo mount -t nfs 10.95.112.179:/home/work/nfs/ /home/work/nfs/

posted @ 2016-03-05 17:27  lian4187  阅读(525)  评论(0编辑  收藏  举报