maxmind provide an updated db that you can download under the license

Bug #314405 reported by Giles Westwood
2
Affects Status Importance Assigned to Milestone
geoip (Ubuntu)
New
Undecided
Unassigned

Bug Description

#!/bin/sh
#Grab the uptodate free geoip country mappings
test ! -d /usr/share/GeoIP && mkdir -p /usr/share/GeoIP ;
wget -a /var/log/geoip.log -O - http://geolite.maxmind.com/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz | gunzip > /usr/share/GeoIP/GeoIP.dat

This can be run via cron to make sure you're kept up to date.

Revision history for this message
TimWintle (timwintle) wrote :

Will that not cause problems if the ip database is currently in use? Will the file handle be released by the application using the api?

Revision history for this message
Giles Westwood (giles-westwood) wrote : Re: [Bug 314405] Re: maxmind provide an updated db that you can download under the license

2009/1/11 TimWintle <email address hidden>

> Will that not cause problems if the ip database is currently in use?
> Will the file handle be released by the application using the api?

Hi Tim,

That is a very good point. It's something I run once a month in the middle
of the night and have been doing for 12 months. To explain I use GeoIP via
the Perl binding from the policyd-weight daemon that I've modified to do
geoip lookups. Would something like a copy then truncate work which is what
I use with tomcat logrotation?

--
------------------------------
Giles Westwood

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.