The NFS network file server simply assumes that the NFS network file server www.2cto. comNFS is short for the Network File System and is mainly used for sharing between linux and linux. NFS is installed by default in the centos system. it depends on two software packages: portmap and nfs-utils. among them, portma...
The NFS network file server simply assumes that the NFS network file server www.2cto.com NFS is short for the Network File System and is mainly used for sharing between linux and linux. NFS is installed by default in centos. it depends on two software packages: portmap and nfs-utils. portmap is started and nfs needs to be started manually. the configuration file of the NFS service is/etc/exports. The structure of the file is as follows:/home/nfs * (sync, ro) The first field is used to define the shared directory; the second field is used to define the connection host can be a domain name or ip address, * represents any host; the third field defines permissions, sync represents synchronization disk, ro represents read-only, rw remote connection allows users to read and write data. The configuration instance first creates a/etc/exports, Mkidr/home/nfs // shared directory Chown-R nfsnobody: nfsnobody/home/nfs // change the user and group Mkdir/mnt/share // create a shared directory Chown-R nfsnobody: nfsnobody/mnt/share // change user and group Ping 192.168.211.128 // you can remotely ping NFS mount-t nfs 192.168.211.128: /home/nfs/mnt/share // mount the file. then, we update the file on NFS. server2 can see the update result.
But in this case, server2 is read-only. To obtain the change permission, you can change the NFS configuration file ro to rw and restart. In this case, both parties can change the shared content. Umount/mnt/share // if not used, unmount umount to Showmount-a/e can be used to manage the shared disks and connected clients.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.