nfs-server.service fails to start when module nfsd is not loaded to the kernel
Issue
- NFS server service fails to start with error below
# systemctl status nfs-server.service
● nfs-server.service - NFS server and services
Loaded: loaded (/usr/lib/systemd/system/nfs-server.service; disabled; vendor preset: disabled)
Active: inactive (dead)
Sep 16 12:41:22 host01 systemd[1]: Dependency failed for NFS server and services.
Sep 16 12:41:22 host01 systemd[1]: Job nfs-server.service/start failed with result 'dependency'.
Sep 16 12:42:00 host01 systemd[1]: Dependency failed for NFS server and services.
Sep 16 12:42:00 host01 systemd[1]: Job nfs-server.service/start failed with result 'dependency'.
Sep 16 12:44:23 host01 systemd[1]: Dependency failed for NFS server and services.
Sep 16 12:44:23 host01 systemd[1]: Job nfs-server.service/start failed with result 'dependency'.
Sep 16 12:48:12 host01 systemd[1]: Dependency failed for NFS server and services.
Sep 16 12:48:12 host01 systemd[1]: Job nfs-server.service/start failed with result 'dependency'.
- Following errors are shown in messages file:
var/log/messages:Sep 30 05:41:25 host01 systemd: Starting Preprocess NFS configuration...
var/log/messages:Sep 30 05:41:25 host01 systemd: Mounting NFSD configuration filesystem...
var/log/messages:Sep 30 05:41:25 host01 systemd: Started Preprocess NFS configuration.
var/log/messages:Sep 30 05:41:25 host01 systemd: Starting NFSv4 ID-name mapping service...
var/log/messages:Sep 30 05:41:25 host01 systemd: Starting NFS status monitor for NFSv2/3 locking....
var/log/messages:Sep 30 05:41:25 host01 systemd: Started NFSv4 ID-name mapping service.
var/log/messages:Sep 30 05:41:25 host01 systemd: Started NFS status monitor for NFSv2/3 locking..
var/log/messages:Sep 30 05:41:25 host01 kernel: Installing knfsd (copyright (C) 1996 okir@monad.swb.de).
var/log/messages:Sep 30 05:41:25 host01 kernel: [<ffffffffc0623192>] ? ftrace_define_fields_nfsd_stateid_class+0xc6/0xc6 [nfsd]
var/log/messages:Sep 30 05:41:25 host01 kernel: [<ffffffffc0623192>] ? ftrace_define_fields_nfsd_stateid_class+0xc6/0xc6 [nfsd]
var/log/messages:Sep 30 05:41:25 host01 kernel: [<ffffffffc05d8b22>] nfsd_reply_cache_init+0xa2/0x100 [nfsd]
var/log/messages:Sep 30 05:41:25 host01 kernel: [<ffffffffc06231f0>] init_nfsd+0x5e/0xe6e [nfsd]
var/log/messages:Sep 30 05:41:25 host01 kernel: nfsd: failed to allocate reply cache
var/log/messages:Sep 30 05:41:25 host01 mount: mount: unknown filesystem type 'nfsd'
var/log/messages:Sep 30 05:41:25 host01 systemd: proc-fs-nfsd.mount mount process exited, code=exited status=32
var/log/messages:Sep 30 05:41:25 host01 systemd: Failed to mount NFSD configuration filesystem.
var/log/messages:Sep 30 05:41:25 host01 systemd: Dependency failed for NFS server and services.
var/log/messages:Sep 30 05:41:25 host01 systemd: Dependency failed for NFS Mount Daemon.
var/log/messages:Sep 30 05:41:25 host01 systemd: Job nfs-mountd.service/start failed with result 'dependency'.
var/log/messages:Sep 30 05:41:25 host01 systemd: Job nfs-server.service/start failed with result 'dependency'.
var/log/messages:Sep 30 05:41:25 host01 systemd: Unit proc-fs-nfsd.mount entered failed state.
Environment
- Red Hat Enterprise Linux 7
- Red Hat Enterprise Linux 8
- Red Hat Enterprise Linux 9
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.