一、配置NFS服务
1. 服务器端安装 NFS与RPC 服务
yum install -y nfs-utils rpcbind
2. 其他工作节点需要安装nfs客户端
yum install -y nfs-utils
3. 启动 RPC 服务
systemctl start rpcbind
Systemctl enable rpcbind
4. 查看 NFS 服务项 rpc 服务器注册的端口列表
rpcinfo -p localhost
5. 启动 NFS 服务
systemctl start nfs
Systemctl enable nfs
6. 启动 NFS 服务后 rpc 服务已经启用了对 NFS 的端口映射列表
rpcinfo -p localhost
7. 在服务器端创建共享目录并设置权限
mkdir -p /home/pvdata/mysql_s
chmod 777 /home/pvdata/mysql_s
8. 修改 NFS 配置文件 /etc/exports
vim /etc/exports
/home/pvdata/mysql_s *(rw,sync,insecure,no_subtree_check,no_root_squash)
9. NFS配置文件