NFS mount failure until DHCP renewal
-
- Starting out
- Posts: 18
- Joined: Sun Aug 07, 2016 8:10 pm
NFS mount failure until DHCP renewal
Hi.
My TS-251 is set up so that a specific "backup" directory is NFS-accessible by a single host on the LAN. After initial setup I could connect just fine, from that single authorized client as expected.
After a while, I started getting "mount errrors" and discovered that they would go away if I manually renewed the DHCP lease on the NAS; this is puzzling because:
1) the lease is static, with a reservation, for all hosts in my LAN
2) the leasetime is 30m so it is normally renewed multiple times during the day (verified in the router logs)
Additional information:
-router (running OpenWRT 15.05.1) is normally rebooted during the night via cronjob
-NAS sleeps from 9am weekdays until I come home and wake it up
-desktop NFS client (Debian Stable, fully up to date) is mosly off except when I need it
-NAS runs 4.2.2 20160901
What gives?
My TS-251 is set up so that a specific "backup" directory is NFS-accessible by a single host on the LAN. After initial setup I could connect just fine, from that single authorized client as expected.
After a while, I started getting "mount errrors" and discovered that they would go away if I manually renewed the DHCP lease on the NAS; this is puzzling because:
1) the lease is static, with a reservation, for all hosts in my LAN
2) the leasetime is 30m so it is normally renewed multiple times during the day (verified in the router logs)
Additional information:
-router (running OpenWRT 15.05.1) is normally rebooted during the night via cronjob
-NAS sleeps from 9am weekdays until I come home and wake it up
-desktop NFS client (Debian Stable, fully up to date) is mosly off except when I need it
-NAS runs 4.2.2 20160901
What gives?
- schumaku
- Guru
- Posts: 43578
- Joined: Mon Jan 21, 2008 4:41 pm
- Location: Kloten (Zurich), Switzerland -- Skype: schumaku
- Contact:
Re: NFS mount failure until DHCP renewal
Does the router reboot also bring the Ethernet link to the NAS down ... and keeping it there for a while?
I'd suggest to use a static IP config here anyway.
I'd suggest to use a static IP config here anyway.
-
- Starting out
- Posts: 18
- Joined: Sun Aug 07, 2016 8:10 pm
Re: NFS mount failure until DHCP renewal
According to the logs, the NAS detects link down events and 4 to 6 seconds later link up events.
How long is "a while"? I wanted to avoid hardcoding addresses but I'll give it a try, thanks.
EDIT:
switched to static IP / DNS on the NAS, rebooted router, still same issue.
now rebooting the NAS as well, we'll see.
How long is "a while"? I wanted to avoid hardcoding addresses but I'll give it a try, thanks.
EDIT:
switched to static IP / DNS on the NAS, rebooted router, still same issue.
now rebooting the NAS as well, we'll see.
- schumaku
- Guru
- Posts: 43578
- Joined: Mon Jan 21, 2008 4:41 pm
- Location: Kloten (Zurich), Switzerland -- Skype: schumaku
- Contact:
Re: NFS mount failure until DHCP renewal
...during the router reboot? Well, this is more a router/embedded switch issue than a NAS problem then...aboaboit wrote:According to the logs, the NAS detects link down events and 4 to 6 seconds later link up events.
-
- Starting out
- Posts: 18
- Joined: Sun Aug 07, 2016 8:10 pm
Re: NFS mount failure until DHCP renewal
Of course it's during router reboot, that's what you asked, right? Anyhow, if it's really a router issue why is just the NAS affected and no other device?schumaku wrote:...during the router reboot? Well, this is more a router/embedded switch issue than a NAS problem then...
Most importantly, why does manually renewing the lease fix the issue, while the periodic renewal (30min) does nothing? My feeling is that the NAS is caching some negative reply from the router and only clears it when forced. For the time being I'm leaving it static: not what I wished for but if it works I'm good
Fingers crossed!
- schumaku
- Guru
- Posts: 43578
- Joined: Mon Jan 21, 2008 4:41 pm
- Location: Kloten (Zurich), Switzerland -- Skype: schumaku
- Contact:
Re: NFS mount failure until DHCP renewal
When somebody want to investigate, the key is what happens with the Kernel in the time the network interface is down, the interface is coming back up, the time until the DHCP server would assign the IP address, ...
-
- Starting out
- Posts: 18
- Joined: Sun Aug 07, 2016 8:10 pm
Re: NFS mount failure until DHCP renewal
Switched to static address but the issue is still here. Rebooting to apply new firmware, will followup if I have more information.schumaku wrote:When somebody want to investigate, the key is what happens with the Kernel in the time the network interface is down, the interface is coming back up, the time until the DHCP server would assign the IP address, ...
EDIT: one day of observation with latest firmware, always with static IP on the NAS, still no go.
Additionally, whereas with the dynamic setting I could just force the NAS to renew the lease to fix this issue, now I need to stop and restart the NFS service.
- schumaku
- Guru
- Posts: 43578
- Joined: Mon Jan 21, 2008 4:41 pm
- Location: Kloten (Zurich), Switzerland -- Skype: schumaku
- Contact:
Re: NFS mount failure until DHCP renewal
Almost convinced the new Network & Virtual Switch App does play games with us (resp. the Kernel handling NFS).
-
- Starting out
- Posts: 18
- Joined: Sun Aug 07, 2016 8:10 pm
Re: NFS mount failure until DHCP renewal
I disabled the daytime standby for the NAS, IP is static, but still no go. I am going to disable the nighttime reboot for the router to check if that makes a difference.schumaku wrote:Almost convinced the new Network & Virtual Switch App does play games with us (resp. the Kernel handling NFS).
EDIT: ok, I think I am making progress but first some additional background: desktop and NAS are on the same switch of a wifi router which is not serving DHCP but simply WDS-bridging to the main router, that serving DHCP and handling the DSL connection. If I reboot the main router, nothing bad happens: mount succeeds. If I reboot the local router / switch, then subsequent mount attempts fail until I renew the NAS IP (if DHCP) or toggle the NFS service.
Now the question is: what's the best way to bring this to the attention of QNAP?
- schumaku
- Guru
- Posts: 43578
- Joined: Mon Jan 21, 2008 4:41 pm
- Location: Kloten (Zurich), Switzerland -- Skype: schumaku
- Contact:
Re: NFS mount failure until DHCP renewal
Temporarily replace the wireless bridge by a network cable, use the same routers / WLAN bridge LAN ports. Chime back if the issue remains.
Doubt NAP can fix all these comparably weak wireless bridges, WDS systems, ...
Doubt NAP can fix all these comparably weak wireless bridges, WDS systems, ...
-
- Starting out
- Posts: 18
- Joined: Sun Aug 07, 2016 8:10 pm
Re: NFS mount failure until DHCP renewal
I'll try that when I have a chance, it would be just for curiosity since I cannot use that solution daily.schumaku wrote:Temporarily replace the wireless bridge by a network cable, use the same routers / WLAN bridge LAN ports. Chime back if the issue remains.
Doubt NAP can fix all these comparably weak wireless bridges, WDS systems, ...
As a workaround, I thought of toggling the NFS shortly after the routers are rebooted. Is there a way to do that from cmdline?
- schumaku
- Guru
- Posts: 43578
- Joined: Mon Jan 21, 2008 4:41 pm
- Location: Kloten (Zurich), Switzerland -- Skype: schumaku
- Contact:
Re: NFS mount failure until DHCP renewal
aboaboit wrote:As a workaround, I thought of toggling the NFS shortly after the routers are rebooted. Is there a way to do that from cmdline?
[~] # /etc/init.d/nfs restart
Shutting down NFS services: OK
Starting NFS services: re-export.
Shutting down NFS mountd:
Starting NFS mountd. Mountd port number = 30000.
OK
[~] #
-
- Starting out
- Posts: 18
- Joined: Sun Aug 07, 2016 8:10 pm
Re: NFS mount failure until DHCP renewal
That simple, uh?schumaku wrote:aboaboit wrote:As a workaround, I thought of toggling the NFS shortly after the routers are rebooted. Is there a way to do that from cmdline?
[~] # /etc/init.d/nfs restart
Shutting down NFS services: OK
Starting NFS services: re-export.
Shutting down NFS mountd:
Starting NFS mountd. Mountd port number = 30000.
OK
[~] #
I'm still asking myself why I expected something more complicated than that
Thanks
-
- Starting out
- Posts: 18
- Joined: Sun Aug 07, 2016 8:10 pm
Re: NFS mount failure until DHCP renewal
Hmm, nope: NFS restart (or even separate stop / start) is not equivalent to disable / enable NFS in the GUI: the former is not a valid workaround, only the latter is.schumaku wrote: # /etc/init.d/nfs restart
I guess I'll try to force a network restart after (WDS) router reboot.
-
- Starting out
- Posts: 18
- Joined: Sun Aug 07, 2016 8:10 pm
Re: NFS mount failure until DHCP renewal
Nope, total failure: NFS restart, NFS stop + NFS start, network restart, network stop + network start, nothing fixes the NFS issue I have like disabling the service from the admin GUI and re-enabling it.schumaku wrote:aboaboit wrote:As a workaround, I thought of toggling the NFS shortly after the routers are rebooted. Is there a way to do that from cmdline?
[~] # /etc/init.d/nfs restart
Either I do not reboot the router or I figure out what the GUI does differently from the cmdline scripts