CentOS配置NFS
2014-01-07 11:09
225 查看
服务端配置
1. 安装nfs-utils和rpcbind
yum install nfs-utils rpcbind
2.设置开机启动服务
chkconfig nfs on
chkconfig rpcbind on
3.启动相关服务
service rpcbind start
service nfs start
4.创建共享目录
mkdir -p /export/primary
mkdir -p /export/secondary
5.编辑/etc/exports文件添加如下内容
vi /etc/exports
/export*(rw,async,no_root_squash,no_subtree_check)
6.刷新配置立即生效
exportfs -a
客户端配置
1. 安装nfs-utils和rpcbind
yum install nfs-utils rpcbind
2.设置开机启动服务
chkconfig nfs on
chkconfig rpcbind on
3.启动服务
servicerpcbind start
servicenfs start
4.创建挂载点
mkdir -p /mnt/primary
mkdir -p /mnt/secondary
5.挂载目录
mount -t nfs server_ip:/export/primary /mnt/primary
mount -t nfs server_ip:/export/secondary /mnt/secondary
6.查看挂载的目录
df -h
7.卸载挂载的目录
umount /mnt/primary
umount /mnt/secondary
8.编辑/etc/fstab,开机自动挂载
vi /etc/fstab
server_ip:/export/primary/mnt/primary nfs rw,tcp,intr 0 1
server_ip:/export/secondary/mnt/secondary nfs rw,tcp,intr 0 1
1. 安装nfs-utils和rpcbind
yum install nfs-utils rpcbind
2.设置开机启动服务
chkconfig nfs on
chkconfig rpcbind on
3.启动相关服务
service rpcbind start
service nfs start
4.创建共享目录
mkdir -p /export/primary
mkdir -p /export/secondary
5.编辑/etc/exports文件添加如下内容
vi /etc/exports
/export*(rw,async,no_root_squash,no_subtree_check)
6.刷新配置立即生效
exportfs -a
客户端配置
1. 安装nfs-utils和rpcbind
yum install nfs-utils rpcbind
2.设置开机启动服务
chkconfig nfs on
chkconfig rpcbind on
3.启动服务
servicerpcbind start
servicenfs start
4.创建挂载点
mkdir -p /mnt/primary
mkdir -p /mnt/secondary
5.挂载目录
mount -t nfs server_ip:/export/primary /mnt/primary
mount -t nfs server_ip:/export/secondary /mnt/secondary
6.查看挂载的目录
df -h
7.卸载挂载的目录
umount /mnt/primary
umount /mnt/secondary
8.编辑/etc/fstab,开机自动挂载
vi /etc/fstab
server_ip:/export/primary/mnt/primary nfs rw,tcp,intr 0 1
server_ip:/export/secondary/mnt/secondary nfs rw,tcp,intr 0 1
相关文章推荐
- [ZT]CentOS下NFS服务器配置
- CentOS 6.X配置 NFS以及启动和mount挂载
- CentOS下torque集群配置(二)集群中配置NFS实现文件共享
- centos fedora nfs kermit tftp 配置
- CentOS 6.5下NFS安装配置
- CentOS 7 安装配置 NFS
- CentOS-5.6-x86_64 下安装配置NFS
- centos6.2下配置nfs
- centos配置nfs服务详细步骤(centos开启nfs服务)
- Centos6.3下DRBD+HeartBeat+NFS配置笔记
- 在CentOS上安装和配置NFS 4.0
- Centos下nfs的配置
- CentOS 6 NFS的安装配置
- CentOS 6.5下NFS安装配置
- centos6.5中配置nfs服务器
- 【CentOS】NFS服务器的安装与配置
- CentOS下NFS网络文件服务器的安装与配置
- Centos 7网络文件系统nfs服务的安装与配置
- CentOS 7 安装配置 NFS
- centos/fedora nfs的配置