Project IGLOo provides IP Geo Location data files for personal and commercial use under the terms and conditions of Apache Software License.
At present it includes IPv4, IPv6 and ASN to Country Code (ISO 3166-1 alpha-2) mapping. The data is in CSV files, and is periodically kept up to date. The data can be imported to Relational and NOSQL databases for faster lookup.
The format of all files is:
(asn|ipv4|ipv6) start,range,country code