Skip to content

mjtrangoni/geoip2_zabbix

Repository files navigation

GeoIP2 Zabbix Build Status

License

Monitoring script for getting the actual host location from GeoIP2-City and expose it to Zabbix.

Getting

$ go get github.com/mjtrangoni/geoip2_zabbix

Building

$ cd $GOPATH/src/github.com/mjtrangoni/geoip2_zabbix
$ make

Configuration

GeoIP2 DB

This program works with the commercial and the lite version of the GeoIP2-City Database. You can choose which one to use.

Templates

For Zabbix 4.2 here

Running

Manually

$ ./geoip2_zabbix <flags>

Zabbix UserParameters

Using zabbix UserParameters, you can call geoip2_zabbix from linux or windows,

Linux

You can build geoip2_zabbix for linux running simply make, and then add this UserParameter to your zabbix-agent.

UserParameter=geoip2.zabbix,/pathtobinary/geoip2_zabbix --path.geoipdb=/pathtodb/GeoIPCityV2.mmdb

Windows

You can crossbuild geoip2_zabbix for windows on linux running simply make crossbuild, and then add this UserParameter to your zabbix-agent.

UserParameter=geoip2.zabbix,PowerShell -NoProfile -ExecutionPolicy Bypass -Command " & 'C:\PathToBinary\geoip2_zabbix.exe' --path.geoipdb=C:\PathToDB\GeoIPCityV2.mmdb"

Grafana Dashboard

WIP

Contributing

Refer to CONTRIBUTING.md

License

Apache License 2.0, see LICENSE.