- This entry was posted on Wednesday, March 30th, 2016 at 11:31 pm and is filed under NIX Posts.You can follow any responses to this entry through the RSS 2.0 feed.
- If all is well, restart NFS server so as to make the share available to NFS clients. Systemctl restart nfs-kernel-server. If firewall is running on NFS server, allow access to the nfs share from the client. Ufw allow from 192.168.43.214 to any port nfs. Reload the firewall to apply the changes: ufw reload Configure NFS Client.
I'm trying to get nfs working on an Ubuntu 16.04.2 LTS. I get the following error: I've already tried reinstalling nfs-common, nfs-kernel-server and other packages following instructions provided in. Jul 20 08:52:09 Ubuntu-mate systemd1: Job nfs-server.service/start failed with result 'dependency'. Jul 20 08:52:09 Ubuntu-mate systemd1: Unit proc-fs-nfsd.mount entered failed state. Jul 20 08:52:09 Ubuntu-mate systemd1: nfs-idmapd.service: control process exited, code=exited status=1 Jul 20 08:52:09 Ubuntu-mate systemd1: Unit nfs.
https://wiki.archlinux.org/index.php/Reporting_Bug_Guidelines
Do NOT report bugs when a package is just outdated, or it is in Unsupported. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#43647 - [nfs-utils] nfs-server fails to start
Opened by Gene (GeneC) - Saturday, 31 January 2015, 21:43 GMT
Last edited by Andreas Radke (AndyRTR) - Saturday, 18 April 2015, 07:38 GMT
| DetailsDescription: nfs-server fails to start Additional info: Similar problems noted last year here: https://lists.archlinux.org/pipermail/arch-general/2014-June/036617.html Today after reboot nfs-server was not running: 2 units fail to start rpc-statd.service nfs-server.service. ------------------------------------- rpc-statd: systemctl status rpc-statd rpc.statd[736]: Version 1.3.2 starting rpc.statd[736]: Flags: TI-RPC rpc.statd[736]: Running as root. chown /var/lib/nfs to choose different user rpc.statd[736]: failed to create RPC listeners, exiting systemd[1]: rpc-statd.service: control process exited, code=exited status=1 systemd[1]: Failed to start NFS status monitor for NFSv2/3 locking.. systemd[1]: Unit rpc-statd.service entered failed state. systemd[1]: rpc-statd.service failed. ------------------------------------- I am unable to start this by hand either - continues to fail same way. I had seen this once a month or so back - but was able to start it by hand after machine was up. ------------------------------------- nfs-server: systemctl-status nfs-server ● nfs-server.service - NFS server and services Loaded: loaded (/usr/lib/systemd/system/nfs-server.service; enabled; vendor preset: disabled) Active: failed (Result: exit-code) since Sat 2015-01-31 16:05:32 EST; 5min ago Process: 743 ExecStart=/usr/sbin/rpc.nfsd $RPCNFSDARGS (code=exited, status=1/FAILURE) Process: 741 ExecStartPre=/usr/sbin/exportfs -r (code=exited, status=0/SUCCESS) Main PID: 743 (code=exited, status=1/FAILURE) rpc.nfsd[743]: rpc.nfsd: writing fd to kernel failed: errno 111 (Connection refused) rpc.nfsd[743]: rpc.nfsd: unable to set any sockets for nfsd systemd[1]: nfs-server.service: main process exited, code=exited, status=1/FAILURE systemd[1]: Failed to start NFS server and services. systemd[1]: Unit nfs-server.service entered failed state. systemd[1]: nfs-server.service failed. ------------------------------------- Machine is fully updated from testing repo. I did try kernel 3.19.rc6 but it does not help. Going over the bug from June 2014 I tried these: systemctl restart proc-fs-nfsd.mount systemctl restart rpcbind systemctl restart nfs-mountd.service systemctl restart rpc-statd.service systemctl restart nfs-idmapd.service systemctl restart rpc-svcgssd.service systemctl restart rpc-statd-notify.service systemctl restart nfs-mountd systemctl restart rpc-gssd.service rpc-svcgssd.service rpc-statd still does not start but now .. it failes with rpc-statd.service start operation timed out. Terminating. Trying to start nfs-server - it too 'times out' After 5 mins i tried again: systemctl start nfs-server which now starts ... rpc-statd is still not running. And the server is once again serving NFS. * package version(s) nfs-utils 1.3.2-1 linux 3.18.5-1 rpcbind 0.2.2-1 * config and/or log files etc. Steps to reproduce: |
Saturday, 18 April 2015, 07:38 GMT
Reason for closing: Fixed
|
NFS allows a linux server to share directories with other UNIX clients over network. NFS server exports a directory and NFS client mounts this directory. RHEL 7 supports two version of NFS – NFSv3 and NFSv4.
NFS server and RPC processes
starting the nfs-server process starts the NFS server and other RPC processes. RPC processes includes:
– rpc.statd : implements monitoring protocol (NSM) between NFS client and NFS server
– rpc.mountd : NFS mount daemon that implements the server side of the mount requests from NFSv3 clients.
– rpc.idmapd : Maps NFSv4 names and local UIDs and GIDs
– rpc.rquotad : provides user quota information for remote users.
Configuring NFS server
1. Install the required nfs packages if not already installed on the server :
2. Enable the services at boot time:
In RHEL7.1 (nfs-utils-1.3.0-8.el7) enabling nfs-lock does not work (No such file or directory). it does not need to be enabled since rpc-statd.service is static.
In RHEL7.1 (nfs-utils-1.3.0-8.el7) this does not work (No such file or directory). it does not need to be enabled since nfs-idmapd.service is static.
3. Start the NFS services:
4. Check the status of NFS service:
5. Create a shared directory:
6. Export the directory. The format of the /etc/exports file is :
Client options include (defaults are listed first) :
ro / rw :
a) ro : allow clients read only access to the share.
b) rw : allow clients read write access to the share.
sync / async :
a) sync : NFS server replies to request only after changes made by previous request are written to disk.
b) async : specifies that the server does not have to wait.
wdelay / no_wdelay
a) wdelay : NFS server delays committing write requests when it suspects another write request is imminent.
b) no_wdelay : use this option to disable to the delay. no_wdelay option can only be enabled if default sync option is enabled.
no_all_squash / all_squash :
a) no_all_squash : does not change the mapping of remote users.
b) all_squash : to squash all remote users including root.
root_squash / no_root_squash :
a) root_squash : prevent root users connected remotely from having root access. Effectively squashing remote root privileges.
b) no_root_squash : disable root squashing.
Example :
7. Exporting the share :
-r re-exports entries in /etc/exports and sync /var/lib/nfs/etab with /etc/exports. The /var/lib/nfs/etab is the master export table. Other options that can be used with exportfs command are :
8. Restart the NFS service:
Configuring NFS client
Centos8 Job For Nfs-server.service Canceled
1. Install the required nfs packages if not already installed on the server :
2. Use the mount command to mount exported file systems. Syntax for the command:
Eample :
Server For Nfs
This example does the following:
– It mounts /home from remote host (remote_host) on local mount point /remote_home.
– File system is mounted read-only and users are prevented from running a setuid program (-o ro,nosuid options).
3. Update /etc/fstab to mount NFS shares at boot time.
Firewalld services to be active on NFS server
Linux Job For Nfs-server.service Canceled
For the NFS server to work, enable the nfs, mountd, and rpc-bind services in the relevant zone in the firewall-config application or using firewall-cmd :