I have a web server in my home network and I’m using ZoneEdit for dynamic DNS. It’s accessible perfectly to everyone outside of my local network, but since I switched to a Gateway 2Wire DSL modem/router I’m unable to use the domain to access the server from my network. I can access it via a local IP or by putting it in my Windows hosts file but this is annoying to do on every computer and for every subdomain.
Any idea how I can fix this? Thanks!
This question should not have been migrated from serverfault.com, as it is a common system administration issue faced by admins and IT guys every day.
In short, certain router setups/network topologies prevent you from accessing the external address of the network from within the internal network, especially when traffic from the external address is sent back to the internal network anyway. Look at the following topology:
[A] Web –> [b]External ip address —> [c]Router/firewall/gateway[d] —> [e]Actual server ip address
The problem is that while users from [A] can see [e] by going to www.imaginaryplace.com, people inside the lan going to that address really want to go straight to [e] – and the router/firewall/gateway setup isn’t bright enough to send traffic coming from [e]s local network all the way to [b] and then back to [e], where it would become confused by the [d] to [c] to [d] path and likely drop the traffic.
The fix is to a) use a different URL for internal traffic, like inside.domain.tld or b) use split DNS where the name server knows that requests coming from certain addresses get
handed addresses on the [e] network, or using hosts files on the internal workstations which override the external DNS requests. On small windows networks, this is a job for batch files.
In most events, the way to fix it is to a) use split dns, where you hand out a different IP address
is it possible that you use port redirection on your router and this device only redirects properly traffic that comes over wan interface? if so – and you cannot reconfigure/upgrade the router – you’re left with ugly hack and putting mapping domain name<->local ip into your hosts file.
Sounds like a DNS issue. Check the DNS servers that your local PCs are using. Switch them temporarily to a different set, such as OpenDNS or Google and see if that solves the problem. If it does, then you know there’s a DNS issue. If your local PCs are getting DHCP from the modem, then they’re probably getting DNS from the modem as well. It’s possible the modem’s DNS cache is corrupt or handing out wrong responses for that domain.
Run Wireshark on a PC and watch the DNS traffic when a call to resolve your domain is made. If that works correctly, then you can attempt to trace the issue to other protocols.
I am a little late to aswer this, but if anyone else encounters this issue, it may be due to a misconfiguration in NAT loopback, if your router allows to modify the routing table you can get it fix, but some routers simply doesn’t support loopback, which is pretty rare nowdays but still happens. This loopback is what allows the router to send the request back to your LAN when it discovers the DNS resolves with it’s own IP.