标签:style blog http color 使用 文件 数据 art
1.安装 nfs 服务yum install nfs-utils rpcbindchkconfig nfs on2.exprotfs 文件/usr/sbin/exportfs -rvcat /etc/exports/home/ 10.0.2.0/24(rw,sync,all_squash,anonuid=501,anongid=501)rw :读写;ro :只读;sync :同步模式,内存中数据时时写入磁盘;async :不同步,把内存中数据定期写入磁盘中;no_root_squash :加上这个选项后,root用户就会对共享的目录拥有至高的权限控制,就像是对本机的目录操作一样。不安全,不建议使用;root_squash :和上面的选项对应,root用户对共享目录的权限不高,只有普通用户的权限,即限制了root;all_squash :不管使用NFS的用户是谁,他的身份都会被限定成为一个指定的普通用户身份;anonuid/anongid :要和root_squash 以及 all_squash一同使用,用于指定使用NFS的用户限定后的uid和gid,前提是本机的/etc/passwd中存在这个uid和gid。介绍了上面的相关的权限选项后,再来分析一下笔者刚刚配置的那个/etc/exports文件。其中要共享的目录为/home,信任的主机为10.0.2.0/24这个网段,权限为读写,同步,限定所有使用者,并且限定的uid和gid都为501。3.启动nfs 服务旧版本service portmap startservice nfs start/etc/init.d/portmap restart/etc/rc.d/init.d/nfs restart新版本/etc/init.d/rpcbind start/etc/init.d/nfs start 4.mountmount -t nfs 10.0.2.69:/home /mnt5.umountumount -l /gome_guest/jsp/Gome
nfs服务,布布扣,bubuko.com
nfs服务
原文地址:http://www.cnblogs.com/xiewenhui/p/3888860.html