Differences between revisions 9 and 20 (spanning 11 versions)
Revision 9 as of 2008-08-14 02:06:35
Size: 2321
Editor: CarlNobile
Comment:
Revision 20 as of 2008-08-14 19:19:40
Size: 2765
Editor: CarlNobile
Comment:
Deletions are marked like this. Additions are marked like this.
Line 3: Line 3:
I have put this HOWTO together from various sources which I will list at the end. I will discuss the process of setting up a server and using a client. I have put this HOWTO together from various sources which I will list at the end. Discuss here is the process of setting up a server and using a client. I'm not going to get very wordy here as this is really a reference for myself. However, if you want to contact me concerning this document, follow the link at the bottom of this page for my contact info.
Line 7: Line 7:
On Debian type systems you can install the the packages as shown below: On Debian derived systems you can install the server packages as shown below:
Line 15: Line 15:
'''Do not bind portmap to the loopback. If you need to reconfigure the portmap run the next two commands to restart the servers.''' '''Do not bind portmap to the loopback. If you need to reconfigure the portmap run the first of the next two commands or edit {{{/etc/default/portmap}}} by hand then restart the servers.'''
Line 26: Line 26:
The following line will permit all 254 C class addresses on the private net to access this mount. The following line will permit all 254 C class addresses on the private net specified to access this mount.
Line 32: Line 32:
This line will permit all 65534 C class addresses on the private net to access this mount. This line will permit all 65534 C class addresses on the private net specified to access this mount.
Line 40: Line 40:
Reread the {{{/etc/ecport}}} file.

{{{
sudo exportfs -ra
}}}

Restart the nfs server.
Line 42: Line 50:
sudo exportfs -a
Line 44: Line 51:

'''Note: See [[ipcalc]] for details of determining the network parameters.'''
Line 51: Line 60:
Line 54: Line 62:
First make a mount point on your remote machine where you want this mount to be located. First make a mount point on your remote machine where you want the server mount to be located.
Line 61: Line 69:
This will mount your {{{/home}}} directory to {{{/share/home}}} on the remote machine. The following will mount your remote {{{/home}}} directory to {{{/share/home}}} on the client machine.
Line 69: Line 77:
'''You will need to restart the servers below:''' '''You will need to restart the servers using the commands below:'''
Line 78: Line 86:
Edit {{{/etc/fstab}}}. Edit {{{/etc/fstab}}} adding the following line:
Line 81: Line 89:
myserver.mydomain.org:/home /shares/home nfs rsize=8192,wsize=8192,timeo=14,intr myserver.mydomain.org:/home /shares/home nfs rw,bg,intr 0 0
Line 84: Line 92:
Look at the mount manual page for other mounting options. Look at the [[http://linux.die.net/man/5/nfs|nfs manual page]] for other mounting options.
Line 86: Line 94:
To test you edit by typing in a terminal the following: To test your edit type in a terminal the following command:
Line 91: Line 99:

'''I would not recommend auto mounting on a wireless network since the system will try to mount your shares before the network is up.'''
Line 99: Line 105:

https://help.ubuntu.com/community/SettingUpNFSHowTo

NFS HOWTO

I have put this HOWTO together from various sources which I will list at the end. Discuss here is the process of setting up a server and using a client. I'm not going to get very wordy here as this is really a reference for myself. However, if you want to contact me concerning this document, follow the link at the bottom of this page for my contact info.

Getting the Packages

On Debian derived systems you can install the server packages as shown below:

sudo apt-get install nfs-kernel-server nfs-common portmap

Configuring portmap

Do not bind portmap to the loopback. If you need to reconfigure the portmap run the first of the next two commands or edit /etc/default/portmap by hand then restart the servers.

sudo dpkg-reconfigure portmap
sudo /etc/init.d/portmap restart

Configuring NFS

Edit the /etc/export file.

The following line will permit all 254 C class addresses on the private net specified to access this mount.

/home 192.168.1.1/24(rw,no_root_squash,no_subtree_check,async)

This line will permit all 65534 C class addresses on the private net specified to access this mount.

/home 192.168.0.0/16(rw,no_root_squash,no_subtree_check,async)

You must execute the following commands after any edit to the /etc/export file.

Reread the /etc/ecport file.

sudo exportfs -ra

Restart the nfs server.

sudo /etc/init.d/nfs-kernel-server restart

Note: See ipcalc for details of determining the network parameters.

Installing Just the Client Software

sudo apt-get install portmap nfs-common

Manual Mounting

First make a mount point on your remote machine where you want the server mount to be located.

cd /
sudo mkdir -p shares/home

The following will mount your remote /home directory to /share/home on the client machine.

sudo mount -t nfs myserver.mydomain.org:/home /shares/home

You may not need the -t nfs in the above command.

You will need to restart the servers using the commands below:

sudo /etc/init.d/portmap restart
sudo /etc/init.d/nfs-common restart

Auto Mounting

Edit /etc/fstab adding the following line:

myserver.mydomain.org:/home /shares/home nfs rw,bg,intr 0 0

Look at the nfs manual page for other mounting options.

To test your edit type in a terminal the following command:

mount /shares/home

http://ubuntuforums.org/showthread.php?t=249889

http://tldp.org/HOWTO/NFS-HOWTO/

https://help.ubuntu.com/community/SettingUpNFSHowTo

NFS HOWTO (last edited 2016-08-16 21:17:56 by CarlNobile)