nfs安装:apt-get install nfs-common nfs-kernel-server portmap
配置文件:/etc/exports
配置文件举例:
$ cat /etc/exports
/home/share 192.168.1.*(rw,sync) *(ro) #所有192.168.1*主机可以访问目录/home/share
配置文件:/etc/exports
配置文件举例:
$ cat /etc/exports
/home/share 192.168.1.*(rw,sync) *(ro) #所有192.168.1*主机可以访问目录/home/share
# exports –rv
服务:/etc/init.d/nfs-kernel-server start|stop|restart
服务:/etc/init.d/nfs-kernel-server start|stop|restart
主机ip地址修改:/etc/network/interfaces
主机DNS:/etc/resolv.conf
服务:/etc/init.d/networking start|stop|restart
主机DNS:/etc/resolv.conf
服务:/etc/init.d/networking start|stop|restart
smb fs 安装:apt-get install smbfs
mount
nfs:mount -t nfs //192.168.2.210:/nfsroot /home/mnt -o nolock
cifs/smb:mount -t cifs //192.168.2.210/lxshare /home/mnt --verbose -o user='u1',passwd='p1'
mount
nfs:mount -t nfs //192.168.2.210:/nfsroot /home/mnt -o nolock
cifs/smb:mount -t cifs //192.168.2.210/lxshare /home/mnt --verbose -o user='u1',passwd='p1'