snapshotpl / ZfSnapGeoip

Maxmind Geoip module for Zend Framework 2
15 stars 4 forks source link

Error during file download for geoip database #7

Closed PurpleHexagon closed 9 years ago

PurpleHexagon commented 9 years ago

Error: PHP Warning: copy(http://geolite.maxmind.com/download/geoip/database/GeoLiteCity.dat.gz): failed to open stream: HTTP request failed! HTTP/1.1 403 Forbidden Error during file download occured

Download console command seems to be failing on all applications we use this module on. Potentially due to changes to geolite.maxmind server config.

snapshotpl commented 9 years ago

It's problem in module or maxmind server? I can download db by browser without issues.

PurpleHexagon commented 9 years ago

It is a problem with the way the module downloads from maxmind server. I assume to do with changes to the web server their end. The issue started a few days ago only when using this modules console command.

We can hit the db download in browser and with wget command. However fails to download using the console command, potentially due to the way php copy command works, (Assume the 403 forbidden is due to the request being invalid, potentially incorrect headers). With the changes in the pull request the console command successfully downloads the db file.

PurpleHexagon commented 9 years ago

Sorry don't think I linked the pull request and issue together correctly earlier ... relates to https://github.com/snapshotpl/ZfSnapGeoip/pull/8

snapshotpl commented 9 years ago

Fixed. Thanks @jjday !