nfs
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
nfs [2015/12/21 12:28] – created luke7858 | nfs [2024/05/23 07:26] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 12: | Line 12: | ||
| nfs-lock / rpc-statd | NFS file locking. Implemented file lock recovery when an NFS server crashes and reboots | | | nfs-lock / rpc-statd | NFS file locking. Implemented file lock recovery when an NFS server crashes and reboots | | ||
| nfs-idmap | Translates user and group ids into names, and vice-versa | | | nfs-idmap | Translates user and group ids into names, and vice-versa | | ||
+ | |||
+ | === Installing (CentOS 7) === | ||
+ | <sxh bash> | ||
+ | systemctl enable rpcbind | ||
+ | systemctl enable nfs-server | ||
+ | </ | ||
+ | |||
+ | <sxh bash> | ||
+ | systemctl start rpcbind | ||
+ | systemctl start nfs-server | ||
+ | systemctl start rpc-statd | ||
+ | systemctl start nfs-idmapd | ||
+ | </ | ||
+ | === Creating NFS Share === | ||
+ | <sxh bash> | ||
+ | mkdir -p / | ||
+ | </ | ||
+ | Now we need to edit / | ||
+ | <sxh bash> | ||
+ | vim / | ||
+ | </ | ||
+ | <sxh bash> | ||
+ | / | ||
+ | </ | ||
+ | \\ | ||
+ | no_root_squash : By default, any file request made by user root on the client machine is treated as by user nobody on the server. (Exactly which UID the request is mapped to depends on the UID of user “nobody” on the server, not the client.) If no_root_squash is selected, then root on the client machine will have the same level of access to the files on the system as root on the server. | ||
+ | \\ | ||
+ | |||
+ | \\ | ||
+ | Once you have edited the / | ||
+ | <sxh bash> | ||
+ | exportfs -r | ||
+ | </ | ||
+ | === Firewall configuration === | ||
+ | <sxh bash> | ||
+ | firewall-cmd --permanent --zone public --add-service mountd | ||
+ | firewall-cmd --permanent --zone public --add-service rpc-bind | ||
+ | firewall-cmd --permanent --zone public --add-service nfs | ||
+ | firewall-cmd --reload | ||
+ | </ |
nfs.1450700924.txt.gz · Last modified: 2024/05/23 07:26 (external edit)