(_,n(Yd5nQ0
vi /etc/exports#and add:oH+Pz5r)K|7{5t'o(Q0
/home/01_CodecVectors192.168.1.*(rw,sync,no_root_squash) 192.168.2.*(rw,sync,no_root_squash):bM*\
xe r$A+[&k!n0
/tftproot/imx31/ *(rw,no_root_squash)D qZV)M9_y0
/mnt/home/nfsroot192.168.1.*(rw,sync,no_root_squash) 192.168.2.*(rw,sync,no_root_squash)51Testing软件测试网fR;\N!WR/^.W8Nb
/mnt/ftproot/incoming192.168.1.*(ro,sync) 192.168.2.*(ro,sync){wbr5|jgd0
/mnt/home/video_codec192.168.1.*(ro,sync) 192.168.2.*(ro,sync)l3D5n:yKRH})w0
6]cR;un3dd/QA0
H"K{*K.g@0
/etc/init.d/nfs restart51Testing软件测试网B7^p;a/Y
i6slh ~S0H\J:j0
Or you can use service to start the NFS service.6T(GQJ!t$f*U!L T0
/sbin/service nfs restart51Testing软件测试网I7E1to`0lY
I
T.O;|g [y5T+l1n%h+j0
1.3MountNFSfor the Linux system
mkdir /mnf/nfs*oK%p*_'Wc0
mount -t nfs -o nolock 10.192.225.215:/01_CodecVectors/ /mnt/nfs51Testing软件测试网H5DYTb!Wd(k&u
mount -t nfs -o nolock 10.192.225.215:/01_CodecVectors/ /mnt/streams3r FH9Gk,w0
3C1e9N#pu?Cy&r:]6_0
mount -t nfs -o nolock,rsize=1024,wsize=1024 10.192.225.222:/rootfs /mnt/nfs51Testing软件测试网MuGo%M#Z/tc-~+H
n!~G:@l6h2m0
Yzb*h4r z
fWi0
2UbuntuNFS:
2.1安装nfs服务器端和客户端
-N.q7lC1j|1Z0
服务器端:sudoapt-get install portmap nfs-kernel-serverb5D/k7iYkCV0
客户机端:sudo apt-get install portmap nfs-common&urbF4Ijg0
2.2配置共享文件
编辑/etc/exports,在其中增加要共享的目录+H*_*\(_ B)L0
sudo gedit /etc/exportsK? \'B#^d0
配置N `&U`4F:m_*R0
/media/sda6/share *(rw,sync)q#^gAH0
/media/sda6/share是要共享的目录,*代表允许所有的网络段访问,rw是可读写权限3nq!W~d$Q6gFj0
保存。51Testing软件测试网&p(UD!xh4G*s3cb
sudo exportfs -raRV3FW`L0
2.3重启服务
sudo /etc/init.d/portmap restart9Qiur6JQ7`*l*x i;Oj0
sudo /etc/init.d/nfs-kernel-server restartY([Wv}C&J0
pH9ma V`5~1D.a"tS(Y0
2.4服务器安装完之后可以这样测试。
$showmount -e51Testing软件测试网j%DIoP({n7UXb
如果看到这样的信息就说明成功了。51Testing软件测试网#ZN:Jo3sol6m;Ch)N
boris@NF140:/etc/default$ showmount -e51Testing软件测试网0Lk
s:z2yNoCusx
Export list for NF140:51Testing软件测试网Y"C)[_aE5D-r2@
/media/sda6/share *51Testing软件测试网'K?1qW}!m QA
51Testing软件测试网8ot!e7]_)OX}"_
2.5在客户机端创建用于挂载的目录
sudo mkdir /mnt/shareVzbq$br:K Q0
sudo chmod 777 /mnt/share/O"D"BR*p:t*l\e$H0
2.6客户就可以加载了
sudo mount 172.16.5.140:/media/sda6/share /mnt/share~!B!N@`1@)Y0
{&LY.V0OQX*a0