linux系统如何启动rpcbind,关于Centos6.8操作系统安装配置nfs、rpcbind服务后实现linux系统间文件数据共享(挂载mount共享路径)...

一、前言

关于多个centos6.8操作系统间实现文件数据资源共享(挂载mount网络文件路径),这边通过在服务端配置nfs(网络文件系统)+rpcbind服务软件,具体操作步骤如下所示。

二、安装步骤

1. 确认服务端安装ndf服务、启动并设置为开机启动[root@centos6 ~]# rpm  -qa|grep  nfs@b@nfs-utils-1.2.3-64.el6.x86_64@b@nfs4-acl-tools-0.3.3-7.el6.x86_64@b@nfs-utils-lib-1.1.5-11.el6.x86_64@b@[root@centos6 ~]# service  nfs  start@b@启动 NFS 服务: [确定]@b@关掉 NFS 配额:[确定]@b@启动 NFS mountd:[确定]@b@启动 NFS 守护进程:[确定]@b@正在启动 RPC idmapd:[确定]@b@[root@centos6 ~]# chkconfig  --list  nfs@b@nfs             0:关闭  1:关闭  2:关闭  3:关闭  4:关闭  5:关闭  6:关闭@b@[root@centos6 ~]# chkconfig nfs  on@b@[root@centos6 ~]# chkconfig  --list  nfs@b@nfs             0:关闭  1:关闭  2:启用  3:启用  4:启用  5:启用  6:关闭

2. 服务端安装配置rpcbind、启动并设置为开机启动[root@centos6 ~]# rpm  -qa|grep  rpcbind@b@rpcbind-0.2.0-11.el6.x86_64 @b@[root@centos6 ~]# chkconfig  --list rpcbind@b@rpcbind         0:关闭  1:关闭  2:启用  3:启用  4:启用  5:启用  6:关闭@b@[root@centos6 ~]# chkconfig  rpcbind  on@b@[root@centos6 ~]# service  rpcbind start@b@[root@centos6 ~]# service  rpcbind status@b@rpcbind (pid  1768) 正在运行...

3. 在服务端的/etc/exports配置共享路径,并重启服务,同时关闭防火墙(比较重要,否则报mount.nfs: Connection timed out)[root@centos6 init.d]# vi  /etc/exports@b@/home/share  *(insecure,rw,async,no_root_squash)@b@@b@[root@centos6 init.d]# service  nfs  restart@b@关闭 NFS 守护进程:[确定]@b@关闭 NFS mountd:[确定]@b@关闭 NFS quotas:[确定]@b@Shutting down RPC idmapd: [确定]@b@启动 NFS 服务: [确定]@b@关掉 NFS 配额:[确定]@b@启动 NFS mountd:[确定]@b@启动 NFS 守护进程:[确定]@b@正在启动 RPC idmapd:[确定]@b@[root@centos6 init.d]# service  rpcbind  restart@b@停止 rpcbind:[确定]@b@正在启动 rpcbind:[确定]@b@@b@[root@centos6 init.d]# chmod  -R 755 /home/share@b@[root@centos6 init.d]# service  iptables  stop@b@iptables:将链设置为政策 ACCEPT:nat mangle filter [确定]@b@iptables:清除防火墙规则:[确定]@b@iptables:正在卸载模块:[确定]@b@@b@@b@[root@centos6 init.d]# cd /home/share@b@[root@centos6 share]# touch  test.txt@b@[root@centos6 share]# echo "123">test.txt

4. 在客户端mount上面服务端分享的nfs路径/home/share(绑定在客户的/home/202),测试成功[root@raid2t 202]# mount -t nfs   192.168.1.202:/home/share/  /home/202/@b@[root@raid2t 202]# cd /home/202@b@[root@raid2t 202]# ls -l@b@总用量 0 @b@-rw-r--r--. 1 root root 4 9月  21 13:59 test.txt

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值