linux的nfs文件共享
2015-08-05 23:11
477 查看
a. 安装nfs服务 #apt-get install nfs-common nfs-kernel-server portmap 其中portmap可能被替换了,会提示selecting 'rpcbind' instead of 'portmap' 所以你检查有没安装rpcbind,不用安装portmap了。 b. 配置nfs服务 #vim /etc/exports 在最后添加上 /nfs/ 192.168.1.*(rw,sync,no_root_squash) /nfs : 共享目录 192.168.1.* : 可以访问这个服务器共享目录的机器 rw,sync,no_root_squash:代表各种属性 c. 重启服务 # /etc/init.d/nfs-kernel-server restart 要先开启portmap服务 d. 使用nfs服务 mount -t nfs -o nolock 192.168.1.100:/a/ /b/ -t vfstype 指定文件系统的类型,通常不必指定。mount 会自动选择正确的类型。 -o nolock。参考http://blog.csdn.net/yhcao0804/article/details/6870296 df -h可以查看有挂载成功, 也可以umount a/看会不会提示没有挂载到,因为没挂载怎么卸载 开发板和虚拟机不通时,例如mount时连接失败,先让2台机器ping通一下,再mount 参考: http://www.cnblogs.com/mchina/archive/2013/01/03/2840040.html http://blog.sina.com.cn/s/blog_7bd0d88201011qtm.html
相关文章推荐
- Linux内核抢占实现机制分析
- Amoeba实现mysql的读写分离 CentOS6.5下
- zeromq学习笔记1——centos下安装 zeromq-4.1.2
- Linux下安装NVIDIA显卡驱动(无集显)
- linux2.6 O(1)调度系统分析
- linux 2.4调度系统分析
- Linux内核配置与编译
- linux 使用匿名管道
- linux 使用命名管道
- linux 使用消息队列
- linux 进程间通信 使用信号量
- linux 使用共享内存
- Linux-命令-crontab
- linux服务器使用iftop查看带宽流量IP
- Linux中设置服务自启动的三种方式
- 初识linux 命令(一)
- Linux Error: 29: Illegal seek
- 初识linux 命令(一)
- 编译开发板提供的linux软件平台
- linux内核内存分配(一、基本概念)