Score:0

Ubuntu Server 22.04 NFS blocked by firewall

cn flag

I have a set of machines with IPs as follows:

Server:  192.168.0.100
Clients: 192.168.0.101 ~ 104

I have installed nfs-kernel-server on the server and nfs-common on all clients. Firewall is enabled on all machines.

I have added firewall rules on the server:

ufw allow nfs
ufw allow from 192.168.0.101 to any port nfs
ufw allow from 192.168.0.102 to any port nfs
ufw allow from 192.168.0.103 to any port nfs
ufw allow from 192.168.0.104 to any port nfs
ufw allow from 192.168.0.0/24 to any port nfs
ufw reload

Output of ufw status:

2049                       ALLOW       192.168.0.0/24
2049                       ALLOW       192.168.0.101
2049                       ALLOW       192.168.0.102
2049                       ALLOW       192.168.0.103
2049                       ALLOW       192.168.0.104
2049                       ALLOW       Anywhere

However, I cannot access the mount point from client machines:

showmount -e 192.168.0.100
clnt_create: RPC: Timed out

If I disable the firewall on the server, I can access the mount point:

showmount -e 192.168.0.100
Export list for 192.168.0.100:
/mnt/nfs 192.168.0.100/24

What is the issue? Why is the firewall blocking nfs even though I have added all the rules? Any help will be highly appretiated.

King Midas avatar
cn flag
Does this answer your question? [nfs is blocked by ufw even though ports are opened](https://askubuntu.com/questions/103910/nfs-is-blocked-by-ufw-even-though-ports-are-opened)
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.