Ubuntu 20.04 云映像:NFS 服务器无法启动

Ubuntu 20.04 云映像:NFS 服务器无法启动

我刚刚安装了 Ubuntu 20.04 云映像(来自这里:https://cloud-images.ubuntu.com/minimal/releases/focal/release/) 在 Proxmox VM 中。然后我安装了 NFS 服务器

apt install nfs-server

但它无法启动,并且 journalctl 中出现以下错误:

Apr 10 18:03:55 servername01 systemd[1]: Starting Preprocess NFS configuration...
-- Subject: A start job for unit nfs-config.service has begun execution
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- A start job for unit nfs-config.service has begun execution.
-- 
-- The job identifier is 563.
Apr 10 18:03:55 servername01 mount[9668]: mount: /proc/fs/nfsd: unknown filesystem type 'nfsd'.
Apr 10 18:03:55 servername01 systemd[1]: proc-fs-nfsd.mount: Mount process exited, code=exited, status=32/n/a
-- Subject: Unit process exited
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- An n/a= process belonging to unit proc-fs-nfsd.mount has exited.
-- 
-- The process' exit code is 'exited' and its exit status is 32.
Apr 10 18:03:55 servername01 systemd[1]: proc-fs-nfsd.mount: Failed with result 'exit-code'.
-- Subject: Unit failed
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- The unit proc-fs-nfsd.mount has entered the 'failed' state with result 'exit-code'.
Apr 10 18:03:55 servername01 systemd[1]: Failed to mount NFSD configuration filesystem.
-- Subject: A start job for unit proc-fs-nfsd.mount has failed
-- Defined-By: systemd
-- Support: http://www.ubuntu.com/support
-- 
-- A start job for unit proc-fs-nfsd.mount has finished with a failure.
-- 
-- The job identifier is 556 and the job result is failed.
Apr 10 18:03:55 servername01 systemd[1]: Dependency failed for NFS Mount Daemon.

“mount: /proc/fs/nfsd: 未知的文件系统类型‘nfsd’。”...看来,缺少了 nfsd 内核模块:

# modprobe nfsd
modprobe: FATAL: Module nfsd not found in directory /lib/modules/5.4.0-1061-kvm

我不知道如何为正在运行的内核安装它

# uname -a
Linux kubix-cnt01 5.4.0-1061-kvm #64-Ubuntu SMP Thu Mar 24 20:55:55 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

任何想法?

提前谢谢

T0mc @

答案1

我发现您在 Launchpad 上发现了一个错误:https://bugs.launchpad.net/ubuntu/+source/linux-meta-kvm/+bug/1968612

TL;DR linux-kvm(在最小云映像中安装的默认内核)不附带 nfsd.ko 模块,因此会破坏nfs-server安装。

作为一种解决方法,用户可以安装不同的内核版本(如linux-generic)或直接选择完整的服务器映像云图片ubuntu-20.04-server-cloudimg-amd64.img)。

相关内容