Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
linux:nfs [2006/03/23 18:02] a |
linux:nfs [2012/10/15 11:57] (current) zagi old revision restored |
||
|---|---|---|---|
| Line 4: | Line 4: | ||
| * [[http:// | * [[http:// | ||
| * [[http:// | * [[http:// | ||
| + | * [[http:// | ||
| + | |||
| + | **/ | ||
| + | | ||
| + | |||
| + | ===== NFS shares get stale after a while or don't mount at all ===== | ||
| + | This might be caused by the fact that the server really wants to have portnumbers below 1024 for the session. Adding insecure to the exports-file fixes that. | ||
| + | Example: | ||
| + | |||
| + | / | ||
| + | |||
| + | ===== NFS configuration for central storage ===== | ||
| + | |||
| + | ==== Configuring The NFS Server ==== | ||
| + | |||
| + | Edit the / | ||
| + | |||
| + | / | ||
| + | |||
| + | The option listing for each machine will describe what kind of access that machine will have. Important options are: | ||
| + | |||
| + | * **ro**: The directory is shared read only; the client machine will not be able to write to it. This is the default. | ||
| + | * **rw**: The client machine will have read and write access to the directory. | ||
| + | * **no_root_squash**: | ||
| + | * **no_subtree_check**: | ||
| + | * **sync**: By default the exportfs command will use async behavior, telling a client machine that a file write is complete - that is, has been written to stable storage - when NFS has finished handing the write over to the filesysytem. This behavior may cause data corruption if the server reboots, and the sync option prevents this. | ||
| + | |||
| + | Let NFS read and make /home available to the network with the exportfs command. | ||
| + | |||
| + | # exportfs -a | ||
| + | |||
| + | Make sure the required nfs, nfslock, and portmap daemons are running and configured to start after the next reboot. | ||
| + | |||
| + | # chkconfig nfslock on | ||
| + | # chkconfig nfs on | ||
| + | # chkconfig portmap on | ||
| + | |||
| + | # service portmap start | ||
| + | # service nfslock start | ||
| + | # service nfs start | ||
| + | |||
| + | ==== Configuring The NFS Client ==== | ||
| + | |||
| + | Make sure the required netfs, nfslock, and portmap daemons are running and configured to start after the next reboot. | ||
| + | |||
| + | # chkconfig nfslock on | ||
| + | # chkconfig netfs on | ||
| + | # chkconfig portmap on | ||
| + | |||
| + | # service portmap start | ||
| + | # service netfs start | ||
| + | # service nfslock start | ||
| + | |||
| + | Now mount the NFS (server) /home to this client | ||
| + | |||
| + | # mount server:/ | ||
| + | |||
| + | Configure autofs edit your / | ||
| + | |||
| + | # vi / | ||
| + | / | ||
| + | |||
| + | Edit file / | ||
| + | |||
| + | # vi / | ||
| + | | ||

