Ticket #1112 (closed New feature: answered)
Obsolete: ActiveIP2Country plugin: More accurate IP-to-Country reporting
| Reported by: | vipsoft | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | 1.4 - Piwik 1.4 |
| Component: | New Plugin | Keywords: | |
| Cc: | Sensitive: | no |
Description
ActiveIP2Country
The ActiveIP2Country plugin uses an IP-to-country database to determine the visitor's country. In contrast, Piwik normally guesses the visitor's country from his/her browser language and region.
Note: due to changes in IP block assignments, ActiveIP2Country does not attempt to correct earlier log_visit data.
This plugin uses any CSV (comma-separated values) file (named "ip-to-country.csv") containing IP address ranges (start and end expressed as longs) followed by a two letter ISO country code. Values may be double quoted. The country code can be upper or lower case.
The plugin will automatically generate a more compact, binary "ip-to-country.dat" file. To regenerate this file, simply remove it.
Performance
On my antiquated Athlon 1.4 GHz processor (test box):
- search overhead adds ~ 2 ms per query
If shared memory is available:
- minimum shared memory segment requires approx: 1 MB
- loading .dat file into memory: ~ 1 ms
If updating the .csv file:
- time to re-generate .dat file: ~ 7s
Requirements
- Piwik 0.5.5 (or above)
To install
- Extract the attached .zip file in the plugins folder.
- Activate the plugin from the Settings | Plugins tab.
For support
- Send me a tweet @vipsoft
- DO NOT CREATE A NEW TICKET HERE

