[Pdns-users] How to use GeoIP2 database with PowerDNS

Aki Tuomi cmouse at cmouse.fi
Sat May 26 17:06:28 UTC 2018


On Sat, May 26, 2018 at 08:14:15PM +1000, Chris Jones wrote:
> Hi there,
> 
> I have successfully setup a pdns instance using the geoip backend and a
> copy of the legacy GeoIP database (from
> https://dev.maxmind.com/geoip/legacy/install/country/). Throughout the
> MaxMind website, I read that this database is end of life in favor for
> GeoIP2 (available at https://dev.maxmind.com/geoip/geoip2/geolite2/).
> 
> The GeoIP legacy database is in the .DAT format, and the GeoIP2 database is
> in a MMDB format. Reading the pdns documentation, it is confusing whether
> MMDB is nativity supported or if I have to do something to the database
> file to make it work.
>

It should work.
 
> My pdns.conf file contains the following parameters when using the GeoIP
> legacy database:
> 
> launch=geoip
> geoip-database-files=/etc/pdns/GeoIP.dat
> geoip-zones-file=/etc/pdns/geo.yml
> 
> That works fine. But when I change the *geoip-database-files* parameter to
> use the MMDB file, it does not work (geo requests are timing out - standard
> records work fine though).
> 
> launch=geoip
> geoip-database-files=/etc/pdns/GeoLite2-City.mmdb
> geoip-zones-file=/etc/pdns/geo.yml
> 
> Has anyone got an example or suggestions on how I can use the GeoIP2
> databases with the pdns-geoip backend?
> 
> System: CentOS 7 + pdns 4.1.3
> 
> Thanks,
> Chris.

Can you provide your geo.yml?

Aki


More information about the Pdns-users mailing list