nfs共享猜测

yum -y install nfs-utils rpcbind
systemctl enable nfs
systemctl enable rpcbind
设置共享目录
mkdir -p /opt/wwwroot
vim /etc/exports
/opt/wwwroot 192.168.50./24 (rw,sync,no_root_squash)
vim /etc/exports
/var/ftp/pub 192.168.50.101(ro) 192.168.50.102(rw)
启动nfs服务程序
systemctl start rpcbind
systemctl start nfs
netstat -anpt | grep rpc
查看本机发布目录
showmount -e
客户机服务资源
yum -y install rpcbind nfs-utils
systemctl enable rpcbind
systemctl start rpcbind
showmount -e 192.168.50.100
手动挂载nfs目录,50.100是nfs服务器的IP
mount 192.168.50.100:/opt/wwwroot /var/www/html(本地目录)
tail -l /etc/mtab
vim /var/www/html/index.html

你可能感兴趣的:(nfs共享猜测)