nfs-server安装 & 挂载

安装nfs服务器端步骤

1、安装命令

yum install -y nfs-utils rpcbind

2、设置开放文件并且开放权限

chmod 777 /home/share/

3、设置/etc/exports填写如下

vi /etc/exports
/home/share *(rw,sync,no_root_squash)

4、启动/重启/开启启动 nfs-server 和 rpcbind

#启动
systemctl start nfs-server 
systemctl start rpcbind

#重启
systemctl restart nfs-server  
systemctl restart rpcbind 

#状态
systemctl status nfs-server  
systemctl status rpcbind 

#开机启动
systemctl enable nfs-server
systemctl enable rpcbind

nfs客户端安装步骤

centos操作系统

1、安装命令

yum install nfs-utils

2、Centos挂盘命令

mount -t nfs,vers=3,local_lock=yes 10.0.10.11:/home/share /app 
#或
mount -t nfs -o nolock 10.0.10.11:/home/share /app

10.0.10.11为服务器端地址

Centos开机启动

vim  /etc/rc.d/rc.local
mount -t nfs -o nolock 10.0.10.11:/home/share /app
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值