maxmind/mmdbwriter

Build geoip2 database

zanpakuto opened this issue · 1 comments

I have created an mmdb file using the golang mmdbwriter, but had a hard time reading it geoip2 readers because of exceptions while reading the file (https://pypi.org/project/geoip2/).

I'm wondering if there is way to create a geoip2 compatible mmdb that could be read by geoip2 readers.

What is the actual difference between geoip2 and mmdbwriter?

MMDB is a data format that allows arbitrarily structured records. The various GeoIP2 databases have metadata and records that follow particular formats that geoip2 expects. If you are building a database from scratch that does not follow the record format of the MaxMind databases exactly, I would recommend reading them with maxminddb in Python rather than geoip2. maxminddb can return data in an arbitrary record format.

All MaxMind databases are made using mmdbwriter in Go or MaxMind::DB::Writer in Perl.