Link to home
Create AccountLog in
Avatar of PlumInternet
PlumInternet

asked on

DNS Local Server

Hello,

We are looking to improve page download performance and overall redundancy by hosting a copy of our website in many different geograpical locations around the world.

We were wondering if it possible to setup DNS servers to look for the closest webserver to send browsers to?

For example lets say I have hosted two copies of the same site, one in the UK and the other in the US. When A US browser does a DNS lookup I would like to point them to the US webserver and when a browser in the UK does a DNS lookup I woud like to point them to the UK webserver.

Is this possible?
ASKER CERTIFIED SOLUTION
Avatar of skullnobrains
skullnobrains

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
Avatar of PlumInternet
PlumInternet

ASKER

Hi Skullnobrains,

Thanks for the comment. The example I provided I guess was rather broad. We were thinking more granular for example we might have web servers on the east coast and west cost of the US or the east coast and west coast of Australia. How would direct browsers to the closest webserver if they were located in US or AU in the example above.

Thanks
you can use subdomains per region

useast.yoursite.com, uswest.yoursite.com, ....

in this case you'll probably need a non-free version of geoip since as far as i can remember the city and region databases are not free. there might be a free version with us states though.

you may also want to consider that distance on the internet might not reflect geographical distance. you could be nearer by being on opposite coasts but using the same ISP than in the same city using different ones.

if you possess your own AS, letting BGP do the work for you might be wiser and simpler
I think an anycast DNS setup might do the trick

http://dyn.com/blog/unicast-vs-anycast-dns-nameserver-routing/
it will, but if you use BGP in order to redirect to the nearest DNS server, it will be better to host multiple copies of the WEB site in various location behind the same IP and let the BGP do the work directly without changing anything in the DNS. if you host both web and dns servers in each site, you will be doing anycast dns "de facto" but not use it as a feature to redirect traffic.

the point of anycast DNS is to make the user use the nearest DNS server but it does not mean it is wise to create inconsistencies in your DNS zone. if you can use the bgp to redirect to the nearest DNS server, you can also use it for the web server without creating either inconsistencies, zones that will be complicated to maintain, and poor quality failover.

both anycast DNS and this way of routing to the nearest site (in terms of internet distance) only apply if you host your own AS
I've requested that this question be closed as follows:

Accepted answer: 0 points for PlumInternet's comment #a39337911

for the following reason:

Tried and tested