Linux NFS 安装部署

1、NFS client:

--安装nfs客户端软件包

yum install nfs-utils rpcbind

systemctl start  rpcbind.service

systemctl enable rpcbind.service

 

--显示NFS服务器上共享的资源目录

showmount -e server_ip

 

--挂载共享目录

mkdir /nfsclient

mount -t nfs server_ip:/data /nfsclient

 

--开机自动挂载

/etc/fstab

server_ip:/data /nfsclient nfs defaults 0 0

 

--准对oracle rman 备份挂载选项

/etc/fstab

server_ip:/data /backup  nfs rw,bg,hard,nointr,rsize=32768,wsize=32768,tcp,actimeo=0,vers=3,timeo=600   0 0

 

2、nfs server:

--安装nfs服务器软件包

yum install nfs-utils rpcbind

systemctl start  rpcbind.service

systemctl enable rpcbind.service

systemctl start  nfs-server.service

systemctl enable nfs-server.service

 

--共享文件、权限分配

/etc/exports

/data client_ip1(rw,sync,all_squash,anonuid=1001,anongid=1001,fsid=0)

/data client_ip2(rw,sync,no_root_squash)

 

--显示NFS服务器上的共享

exportfs -v

posted @   踏雪无痕2017  阅读(56)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· 分享4款.NET开源、免费、实用的商城系统
· 全程不用写代码,我用AI程序员写了一个飞机大战
· MongoDB 8.0这个新功能碉堡了,比商业数据库还牛
· 记一次.NET内存居高不下排查解决与启示
· 白话解读 Dapr 1.15:你的「微服务管家」又秀新绝活了
点击右上角即可分享
微信分享提示