GeoLitCity.dat reported as broken on IIS server

I have been using piwik for some time on linux server now. Recently, we had to move to windows server with IIS instead of apache-linux. We have been using GeoIP (Php) option for Geolocation detection and had included GeoLiteCity.dat in misc directory.

But since we had moved the server to IIS, we had message showing that the same database was broken.

Following is the error message it showed:

Error: Piwik tried checking the location of a known IP address (, but your server returned ‘Unknown, Unknown, Unknown’. If this provider were configured correctly, it would return ‘Besançon, A6, FR’.

Does IIS-Windows server require any separate configuration for geolocation? Piwik version - 2.15.0

You don’t need anything within IIS for geolocation. Just need the geoloc DB which will go within the misc folder. Go to settings and refresh the page after DB file for geoloc is in misc folder. The sub Message for geolocation should say installed. Then check box to enable.

I have already done this. It shows the database as broken.

Are you sure about the database name? It’s supposed to be GeoIPCity.dat .

To install, you download the ZIP version of the GeoLite City database from GeoLite Legacy Downloadable Databases « MaxMind Developer Site . You then unzip this file to produce GeoLiteCity.dat which should be renamed as GeoIPCity.dat before use on the server.

1 Like

Yes. I have file two copies with both names.

PECL or PHP… try using PHP with instructions as laid out by @canajun2eh
Very simple to install and configure.

Again, as I have explained, I have ALREADY done that.

Got it to work. We are hosting it on Azure Webapp. Seems the issue was with Azure deployment process.

thanks… can you clarify what exactly the issue was.