Networked Media Tank

Normale Version: error in /etc/exports: Local network not allowed to access nfs share
Du siehst gerade eine vereinfachte Darstellung unserer Inhalte. Normale Ansicht mit richtiger Formatierung.
Hi folks,

think, i've found a bug in nfs server config file /etc/exports. This one got me really mad, because i couldn't mount the nfs share from the nmt onto my linux box.
I couldn't find it in the faq, so i'm posting it here.

Being a linux user, i got really mad about the fact, that i couldn' get access to the nfs share of my hdx 1000 and was forced to use smb or ftp instead.
With showmount -e or cat /etc/exports (via telnet) i could see, that /etc/exports had a wrong subnet definition in it to allow hosts on that subnet to mount the nfs share. In this case "wrong" means, that it wasn't the same subnet i use in my home network.

I found, that /etc/exports gets rewritten by the network initialization process at least every reboot of the box. But this process seems unable to deal with subnet masks other than 24 bits (class C).

To give an example:

subnet: 192.168.214.128/28 e.g. 16 host addresses from 128 to 143.
If everything is set to DHCP in the hdx, the network address and mask is set via DHCP (DHCP server in my dsl router). After rebooting the hdx, /etc/exports looks like this:
share 192.168.214.0/255.255.255.240 (rw,sync,root_squash,anonuid=1001,anongid=1001)
The mask is correct but the network starts at host address 0 and the range is 0-15, which doesn't fit to my subnet.
As a result, no host within the network was allowed to access the nfs share. Angry

To fix this, my only chances were to reconfigure my home network to class c or to manually configure IP on the hdx accordingly i.e. give it an address from my range and a class c network mask.

Is this just a bug in hdx or does pch behave the same way?

So why not just export /share to the rest of the world using the asterisk wildcard?
This would avoid trouble, if someone tries to access via nfs from different subnets.

happy debugging,

Thomas

HDX 1000
FW: 50-17-091022-15-HDD-403-000
NMT: 00-17-091014-15-HDD-403
Referenz-URLs