mount.nfs: requested NFS version or transport protocol is not supported
Asked Answered
P

9

27

NFS Mount is not working in my RHEL 7 AWS instance.

When I do a

mount -o nfsvers=3 10.10.11.10:/ndvp2 /root/mountme2/

I get the error:

mount.nfs: requested NFS version or transport protocol is not supported

Can anyone point me where I am wrong? Thanks.

Preempt answered 6/9, 2016 at 11:4 Comment(1)
Yes, NFS Utils was not installed on my AWS instance, >yum install -y nfs-utils fixed itPreempt
G
22

Check the nfs service is started or reboot the nfs service.

Gilges answered 6/10, 2016 at 15:24 Comment(2)
On Ubuntu you can check the status with sudo systemctl status nfs-kernel-serverUnheardof
This was it for me - on OpenSUSE, it's systemctl status nfs-server.service and systemctl start nfs-server.service.Nosy
S
6

A precision which might be useful for the dump (like me): systemctl status nfs-server.service and systemctl start nfs-server.service must be executed on the server!

Sculpin answered 8/5, 2021 at 18:47 Comment(0)
D
5

If you're giving a specific protocol to connect with, also check to make sure your NFS server has that protocol enabled.

I got this error when trying to start up a Vagrant box, and my nfs server was running. It turns out that the command Vagrant uses is:

mount -o vers=3,udp,rw,actimeo=1 192.168.56.1:/dir/on/host /vagrant

Which specifically asks for UDP. My server was running but it was not configured to enable connecting over UDP. After consulting /etc/nfs.conf, I created /etc/nfs.conf.d/10-enable-udp.conf with the following contents to enable udp:

[nfsd]
udp=y

The name of the file doesn't matter, as long as it's in the conf.d directory and ends in .conf. Depending on your distribution it may be configured differently. You can directly edit nfs.conf, but using a conf.d file is more likely to preserve the changes after upgrading your system.

Dropsical answered 30/12, 2022 at 18:28 Comment(0)
E
4

sudo systemctl status nfs-kernel-server In my case this package was not running and the issue was in /etc/exports file where i was having same IP address for two machines. So i commented one ip address for the machine and restarted nf-kernel-server using sudo systemctl restart nfs-kernel-server and reload the machine. It worked.

Eagre answered 11/9, 2020 at 14:15 Comment(0)
O
3

Some additional data

If, like me, you've deleted a VM without shutting it down right you might also need to manually edit the file /etc/exports because NFS is trying to connect to it and fails but doesn't continue with the next, it just dies.

After that you can manually restart as mentioned in other answers.

Ornithorhynchus answered 15/6, 2021 at 13:45 Comment(0)
S
2

In my case, a simple reload didn't suffice. I had to perform a full restart:

sudo systemctl restart nfs-kernel-server
Saltcellar answered 18/7, 2021 at 16:50 Comment(0)
F
2

In my case, it didn't work correctly with version NFS 4.1. So in Vargantfile in each place where is type: 'nfs' I added coma and nfs_version: 4, nfs_udp: false

Here is more detailing explanation NFS

Flautist answered 8/9, 2022 at 10:34 Comment(0)
A
0

Try to ping IP address of the server "ping " from client "ping , if you get reply then install nfs server on the host. Then edit /etc/exports file don't forget to add port along with IP address

Annotate answered 20/1, 2023 at 10:37 Comment(0)
I
-2

I got the solution: make an entry in nfs server /etc/nfsmount.conf with Defaultvers=3 .

There will # Defaultvers=3 just unhash it and then mount on nfs client.

Issue will be resolved!

Immerge answered 21/7, 2020 at 8:8 Comment(1)
its not solved for me and solved as the given above steps.Immerge

© 2022 - 2024 — McMap. All rights reserved.