Configure GeoIP databases
Use the bundled country database or download GeoLite2 city and ASN databases.
Use the bundled country database by default, or add MaxMind credentials for city and ASN enrichment.
-
For country-only geolocation, leave
SUPERMETRY_GEOIP_PATHempty. Supermetry loads its bundled DB-IP Lite database. -
To use MaxMind GeoLite2 data, add both credentials and choose editions in the environment file.
SUPERMETRY_MAXMIND_ACCOUNT_ID=YOUR_ACCOUNT_IDSUPERMETRY_MAXMIND_LICENSE_KEY=YOUR_LICENSE_KEYSUPERMETRY_MAXMIND_EDITIONS=GeoLite2-City,GeoLite2-ASNSUPERMETRY_DATA_DIR=/var/lib/supermetryAllowed editions are
GeoLite2-City,GeoLite2-ASN, andGeoLite2-Country. Supermetry validates existing files and downloads missing editions during startup. -
Restart Supermetry.
Terminal window sudo systemctl restart supermetrysudo systemctl status supermetry --no-pager -
To force an update later, run:
Terminal window sudo -u supermetry env SUPERMETRY_ENV_FILE=/etc/supermetry/supermetry.env \/usr/local/bin/supermetry geoip updateWith MaxMind configured, Supermetry also checks for updates every 24 hours.
-
Keep the geolocation credit visible in the dashboard footer. It shows IP geolocation by DB-IP.com for the bundled data or IP geolocation by MaxMind for GeoLite2 data.
What you should see: startup succeeds and the footer names the active GeoIP provider.