Skip to content

Want to use Geolocation DB csv file for nginx #8

@jkuj6

Description

@jkuj6

I want to use your https://ipapi.is/developers.html#geolocation-database csv file for nginx, however it seems im unable to easily convert it to .dat.

Do you have an easier way to do this?

At the moment im facing a few problems.

  1. I tried using https://github.com/ipinfo/mmdbctl to convert it however there is an issue with the CIDR notation, so i opened an issue here is ipapi csv's conversion supported? ipinfo/mmdbctl#32 but no reply yet.

  2. Then i tried creating my own script to first fit the same format of the csv file as that of ipinfo, i was able to adjust the csv file, except for one issue that i noticed in your csv DB when trying to then use mmdbctl...

mmdbctl import --in geolocationDatabaseIPv4_converted.csv --out data.mmdb
warn: couldn't insert line '154.17.129.024,154.17.129.024,154.17.0.0,Warsaw,Mazovia,Poland,52.22977,21.01178,05-077,Europe/Warsaw'
writing to data.mmdb (1278428 entries)

This 154.17.129.024 is incorrect from your DB. id appreciate if you could fix it.

After i successfully convert it to .mmdb, i can then finally use yet another tool to convert the .mmdb into legacy .dat for usage with nginx.

Finally, to avoid so many conversion tools, Id really appreciate it if you could have your csv file ready for use with nginx, in either .dat or in .mmdb format, or even in a compatible CSV format that is easily converted with mmdbctl.

thanks in advance

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions