Linux安装配置NFS方法
1、查看是否安装rpm -qa |grep nfsrpm -qa |grep rpcbind

2、使用yum -y install nfs-utils rpcbind命令进行安装

3、关闭防火墙,selinux[root@master ~]# systemctl stop firewalld.service[root@master ~]# setenforce 0

4、禁止防火墙开机自启动systemctl disable firewalld.service

5、启动服务,一定要先启动rpc再启动nfsnfs需要向rpc注册,rpc一旦重启,所以注册的文件都丢失,其他向注册的服务都需要重启启动rpc服务:systemctl start rpcbind.service 启动nfs服务:systemctl start nfs.service

6、查看服务启动的状态systemctl status rpcbind.servicesystemctl status nfs.service

7、vi /etc/exports/mnt *(rw,sync,no_root_squash)

8、重启rpcbind再重启nfs:重启rpc服务:systemctl restart rpcbind.service 重启nfs服务:systemctl restart nfs.service

9、在客户端进行挂载mount -t nfs 192.168.137.139:/mnt /tmp
