Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I run a site that is behind a Squid reverse proxy which delivers most of the content cached (including html, not only images, etc.). I need to show a different content for our users located in the US. In order to do that, what solutions do we have?

I thought about using some geo dns service like edgedirector.com and move the American users to a different IP but I have serious doubts about geo DNS solutions. I understand that the edgedirector can only know the location of the ISP's DNS server (or OpenDNS, Google Public DNS, etc.) used by the client but not the client's location. I do not really understand how can they know the IP of the client, teorically the client do not need to query directly edgedirector.

Another solution I thought was using javascript and MaxMind GeoIP Javascript Web Service or Google API client location but that would be too slow.

I also thought about using some reverse proxy like Squid, Varnish, Ngninx, etc. which works directly with Maxmind software (or other software) without the need to go to the backend (like for example a cached copy for each country). Do not know if that is possible with Squid or with some other reverse proxy.

share|improve this question
add comment

1 Answer

If two users one US and the other non US request for the same file static.html and you want to show a different version to each of them then squid will not help.You can use MaxMind's GeoIP with nginx.

http://wiki.nginx.org/HttpGeoIPModule

share|improve this answer
    
Well the URL can be different. Maybe we should run a perl script in the homepage which query GEOIP_MEMORY_CACHE of Maxmind GeoIP Country and then forwards the user to a different URL depending on the country (that allows us to cache the "rest" of the site since the URL are differents). –  Zillo Apr 5 '11 at 10:51
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.