Difference between revisions of "Network File System (NFS)"
Jump to navigation
Jump to search
Rafahsolis (talk | contribs) (Created page with "Debian = Server = = Install = sudo apt install nfs-kernel-server nfs-common = Client = = Install = sudo apt install nfs-common") |
Rafahsolis (talk | contribs) |
||
| Line 1: | Line 1: | ||
Debian | Debian | ||
= Server = | = Server = | ||
| − | = Install = | + | == Install == |
sudo apt install nfs-kernel-server nfs-common | sudo apt install nfs-kernel-server nfs-common | ||
| + | == Exporting Directories == | ||
| + | === Create Directories === | ||
| + | mkdir /home/client1 | ||
| + | chown nobody:nogroup /home/client1 | ||
| + | chmod 755 /home/client1 | ||
| + | mkdir /var/www | ||
| + | chown root:root /var/www | ||
| + | chmod 755 /var/www | ||
| + | |||
| + | === Add to export === | ||
| + | sudo nano /etc/exports | ||
| + | /etc/exports | ||
| + | # Save all files with user:group = nobody:nogroup | ||
| + | /home/client1 192.168.0.101(rw,sync,no_subtree_check) | ||
| + | # Preserve files ownership and permissions (no_root_squash allows root to access folder) | ||
| + | /var/www 192.168.0.101(rw,sync,fsid=0,crossmnt,no_subtree_check,no_root_squash) | ||
= Client = | = Client = | ||
| − | = Install = | + | == Install == |
sudo apt install nfs-common | sudo apt install nfs-common | ||
Revision as of 12:06, 12 August 2018
Debian
Server
Install
sudo apt install nfs-kernel-server nfs-common
Exporting Directories
Create Directories
mkdir /home/client1 chown nobody:nogroup /home/client1 chmod 755 /home/client1
mkdir /var/www chown root:root /var/www chmod 755 /var/www
Add to export
sudo nano /etc/exports
/etc/exports
# Save all files with user:group = nobody:nogroup /home/client1 192.168.0.101(rw,sync,no_subtree_check) # Preserve files ownership and permissions (no_root_squash allows root to access folder) /var/www 192.168.0.101(rw,sync,fsid=0,crossmnt,no_subtree_check,no_root_squash)
Client
Install
sudo apt install nfs-common