Reference Blog: www.linuxidc.com/Linux/2017-02/141150.htm
1 Installing NFS Services
sudo apt-get install nfs-kernel-server Nfs-common
2 Setting Mount directory permissions
sudo vim/etc/exports
Assuming that the NFS shared directory is/HOME/RYAN/NFS, allowing all clients access, the/etc/exports file can be written as:
/home/ryan/nfs * (Rw,sync,no_subtree_check)
Restart Service
Sudo/etc/init.d/nfs-kernel-server restart
3 Mount NFS Directory
To install the MOUNT,NFS client first
sudo apt install mount Nfs-common
The simplest format for mounting commands is
Mount NFS Server IP: Shared directory local mount point directory 1
4 Mount under Win7
Open the Control Panel and locate the program.
Locate the Turn Windows feature on or off.
Locate the NFS service and tick install.
- 5
Go back to the command prompt and enter the SHOWMOUNT-E + server IP address to confirm the mount point.
Then mount with the Mount command, and the following z: is the assigned letter.
But there is a problem that has not been solved, is the Win7 will have garbled problems
5 under the Mac system
There are two ways
1sudo mount-o resvport 192.168.1.104:/media/***/mnt
2 on the server side
sudo vim/etc/exports
Put/home/ryan/nfs * (Rw,sync,no_subtree_check)
/home/ryan/nfs * (rw,sync,insecure)
Linux NFS server builds and uses Windows,macos system mount directory