I have a NAS at home with dual lan cable connected with two different subnets.
- lan1: 192.168.31.185 on subnet 192.168.31.0/24
- lan2: 192.168.10.42 on subnet 192.168.10.0/24
And on this NAS server, there is a web service exposing port 5001. Which I want to access from my office.
As the 192.168.10.0/24 subnet gateway router have access to the Internet. I setup DDNS and port forwarding rules on it.
- port-forwarding rule: ddns-domain.com:5001 -> 192.168.10.42:5001
But testing showed it's not working... Debugging start
There is a PC with address 192.168.10.38 on the same 192.168.10.0/24 subnet.
Try accessing 192.168.10.42:5001 from both PC & gateway router, works well
Setup a demo web service on PC:5001, change the port-forwarding rule: ddns-domain.com:5001 -> PC:5001, access from my mobile 4G network, works well
I'm confusing after this as I used to thought the port forwarding is kind of a special reverse proxy. Which should be working if:
- resource provider can be accessed from the proxy
- proxy can be accessed from its own network address
Which both confirmed ok in the debugging process before. So what should I looking into to find out the problem then?