GeoIP DNS in BIND9 and PowerDNS

I'm looking to optimize my content distribution network with GeoIP DNS services!

While it seems possible with BIND, I'm going to use PowerDNS. Errr... actually, it turns out that it is not possible to route by US states - particularly coasts - that would be nice!

Another change I'm making is to use BIND because apparently NSD3 isn't providing glue records for DNS queries where the target host's name servers are on another domain.

http://www.geoscaling.com also caught my interest, but I haven't tried it out yet.

Actually, I am going to use BIND9 - the acl and view capabilities make it fairly easy. However, I'm actually not going to use it for optimizing via geo-location, I'm just going to split requests so that all of my distribution nodes get used, without having to use a CNAME-to-multiple A setup.

view "north_america" {
      match-clients { US; };
      recursion no;
      zone "evenserver.com" {
            type master;
            file "/etc/bind/zones/evenserver.com.us.zone";
      };
};
acl "US" {
  3.0.0.0/8;
  4.0.0.0/12;
  4.16.0.0/16;
  4.17.0.0/17;
  4.17.128.0/22;
};

Seriously though, these acls with BIND9 are AWESOME!! They can also be used for internal networks - returning local addresses to local clients.

PROGRESS:

  • I've confirmed that BIND is the right choice for me, but I've also realized I need to separate the geoip DNS distribution servers from the higher level static A record services.
By Albert on June 11, 2010 11:49 PM

Categories:

1 Comment

Others might look into http://geoipdns.org/ as a possible solution. Although for simplicity the example in the documentation demonstrates east / central / west, it can be made to operate on the state or finer level as well.