CentOS7挂载NFS报错:mount.nfs: Protocol not supported

Linux2022-08-24
CentOS7挂载NFS报错:mount.nfs: Protocol not supported-下一朵云

CentOS7挂载NFS报错:mount.nfs: Protocol not supported

[root@centos /]# mount -t nfs -o rw 192.168.1.20:/nfserver /nfs
mount.nfs: Protocol not supported

查找网上后所有的内容基本就是以下两种答案:

1.内核不支持NFS,需要配置内核支持
2.busy box的mount需要支持NFS

其实CentOS7的问题都不是这些,以上的答案也无法解决问题

从报错提示可以看出是协议不受支持,那么我们就指定一下nfs协议版本

mount -t nfs -o rw,nfsvers=3 192.168.1.20:/nfserver /nfs

将nfsvers指定为3(nfsvers=3),结果挂载成功!如图2

CentOS7挂载NFS报错:mount.nfs: Protocol not supported-下一朵云
图1 挂载成功