====== IP2Location LITE Geo Metrics ======
This article helps with providing steps to install IP2 Location Geo App in Trisul Network Analytics.
**
Create a Geo based metering in Trisul using the IP2Location LITE databases.
**
This app processes the following CSV databases and provide data in UI.
- **ASN-Lite**:Metrics based on Autonomous System Number.
- **DB3-Lite**:Metrics based on Country and City.
- **P2-Lite**:Metrics based on Proxies.
{{:tips:ip2loc-geo.png?400|}}
===== Installation =====
You can install the app by logging in as admin and selecting //Web Admin > Manage > Apps//.
{{:tips:geoiploc-admin.png?600|}}
* You must install the IP2Location Databases from [[https://lite.ip2location.com/]].
* Unordered List ItemYou need to procure the DOWNLOAD_TOKEN and get theinstaller script installfeed.sh to download and compile the databases.
* To compile the database,Run the following.
curl -O https://raw.githubusercontent.com/trisulnsm/apps/master/analyzers/ip2location/installfeed.sh
bash installfeed.sh DOWNLOAD_TOKEN
Please ensure you restart the probe node after this step.
===== Manual lookup using the checkip tool =====
You can run the checkip.lua tool to manually lookup for any IP in command line.
{{:tips:geoipcommand.png?600|}}
===== Viewing Data =====
- This app creates four separate counter groups named 'IP2LOC-Country/ASN/City/Proxy'.
- You can analyse the counters by selecting// Retro > Retro Counters//.
{{:tips:ip2locasn.png?600|}}
{{:tips:ip2loc-country.png?600|}}
===== Cron Updates =====
- You can update the IP2LOC Database list every week using the script installfeed.sh.
- The updates are automatically picked up.
crontab -e -u trisul
# then add this line
0 0 * * * /usr/local/share/trisul-probe/plugins/installfeed.s