home_server:home_server_setup:other_services:nfs

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
home_server:home_server_setup:other_services:nfs [2020-03-22 Sun wk12 15:28] – [NFS Client] baumkphome_server:home_server_setup:other_services:nfs [2023-12-26 Tue wk52 11:37] (current) baumkp
Line 1: Line 1:
 +{{tag>linux debian nfs fstab server}}
 ======NFS====== ======NFS======
 There are a lot of resources online for NFS (Network File System).  Nevertheless I decided to place my notes here to help me with my configuration, as there are a number of nuances that such notes will potentially assist with in the future. Sadly a number of resources I use seem out of date, not updated and/or possible subject to disappearance. There are a lot of resources online for NFS (Network File System).  Nevertheless I decided to place my notes here to help me with my configuration, as there are a number of nuances that such notes will potentially assist with in the future. Sadly a number of resources I use seem out of date, not updated and/or possible subject to disappearance.
Line 9: Line 10:
   *Havetheknowhow.com [[http://www.havetheknowhow.com/Configure-the-server/Configure-NFS.html|How to configure NFS Version 4 (NFS4) on Ubuntu Server]]   *Havetheknowhow.com [[http://www.havetheknowhow.com/Configure-the-server/Configure-NFS.html|How to configure NFS Version 4 (NFS4) on Ubuntu Server]]
   *die.net [[https://linux.die.net/man/5/exports|exports(5) - Linux man page]]   *die.net [[https://linux.die.net/man/5/exports|exports(5) - Linux man page]]
 +  *[[https://www.golinuxcloud.com/unix-linux-nfs-mount-options-example/|NFS mount options | NFS exports options | Beginners Guide]]
 +  *[[https://www.quora.com/What-are-the-differences-between-bind-mounts-and-symlink-on-Unix|What is a bind mount?]]
 +  *[[https://www.quora.com/What-are-the-differences-between-bind-mounts-and-symlink-on-Unix|What are the differences between bind mounts and symlink on Unix?]]
  
 Some other interesting nfs related commands: Some other interesting nfs related commands:
   * ''mountstats'' give client side nfs operation statistics   * ''mountstats'' give client side nfs operation statistics
   * ''showmount'' Shows the clients (IP addresses) mounted to the nfs server   * ''showmount'' Shows the clients (IP addresses) mounted to the nfs server
-  * ''nfsstat'' Shows some nfs server server statistics +  * ''nfsstat'' Shows some nfs server server statistics 
 +  
 +----
 =====NFS Server===== =====NFS Server=====
   *''sudo apt install nfs-kernel-server'' to install   *''sudo apt install nfs-kernel-server'' to install
Line 55: Line 61:
 =====NFS Client===== =====NFS Client=====
   *''sudo apt install nfs-common'' to install the nfs client   *''sudo apt install nfs-common'' to install the nfs client
- 
  
  
 To apply configuration changes ''sudo systemctl restart nfs-client.target'' To apply configuration changes ''sudo systemctl restart nfs-client.target''
  
-The base client configurations options are given in: ''sudo vim /etc/default/nfs-common''. //However the current base options meet our needs and do not need to be modified.//+The base client configurations options are given in: ''sudo vim /etc/default/nfs-common''. //However the current base options meet our needs and do not need to be modified.//  
 +  *<fs smaller>NEED_STATD=no :(default) we do not need to change the standard port number used </fs> 
 +  *<fs smaller>NEED_GSSD=no  :(default) we do not use kerebos security</fs> 
 +  *<fs smaller>NEED_IDMAPD=no:(default) we do not need to map gid and uid with names </fs>
  
-  *''sudo mount -t nfs -o rw,vers=4 192.168.1.5:/export/storage /mnt/storage'' to mount just the specific directory.+Mounting the nfs client manually: 
 +  *''sudo mount -t nfs -o rw,vers=4 192.168.1.5:/storage /mnt/storage'' to mount just the specific directory.
   *''sudo mount -t nfs -o rw,vers=4 192.168.1.5:/export /mnt'' to mount all the defined exports.   *''sudo mount -t nfs -o rw,vers=4 192.168.1.5:/export /mnt'' to mount all the defined exports.
   *''sudo unmount /mnt/storage'' to unmount   *''sudo unmount /mnt/storage'' to unmount
 +
 +Check status of clients:
   *''findmnt'' to list file system in tree format or ''findmnt -l'' in flat list.   *''findmnt'' to list file system in tree format or ''findmnt -l'' in flat list.
  
-<- home_server:home_server_setup:other_services:disk|Prev ^ home_server:home_server_setup:other_services:index|Start page ^ home_server:home_server_setup:other_services:back-up_server|Next ->+To allow automatic boot of nfs clients: ''sudo vim /etc/fstab'' 
 +<code> 
 +192.168.1.5:/export  /mnt  nfs4 bg 0 0  
 +</code> 
 + 
 +---- 
 + 
 +<- home_server:home_server_setup:other_services:disk|Prev ^ home_server:home_server_setup:other_services:index|Start page ^ home_server:home_server_setup:other_services:rsync|Next ->
  
  • /app/www/public/data/attic/home_server/home_server_setup/other_services/nfs.1584862139.txt.gz
  • Last modified: 2023-04-30 Sun wk17 17:44
  • (external edit)