allinurl / goaccess

GoAccess is a real-time web log analyzer and interactive viewer that runs in a terminal in *nix systems or through your browser.
https://goaccess.io
MIT License
18.37k stars 1.11k forks source link

ASN Unknown #2489

Closed Provyzor closed 1 year ago

Provyzor commented 1 year ago

Hi!

ASN Unknown. How to configure ASN database location?

allinurl commented 1 year ago

Just pass the mmdb file as an option, e.g.,

goaccess access.log --geoip-database=/path/GeoLite2-ASN.mmdb -o report.html --log-format=COMBINED

You can find the db in multiple places, e.g.,

https://db-ip.com/db/download/ip-to-asn-lite https://github.com/P3TERX/GeoLite.mmdb

Provyzor commented 1 year ago

And if I use --geoip-database option in goaccess.conf? I point to GeoLite2-City.mmdb there.

allinurl commented 1 year ago

You can use multiple databases as of v1.7. Just point to different files. e.g.,

goaccess access.log --geoip-database=/path/GeoLite2-ASN.mmdb --geoip-database=/path/GeoLite2-City.mmdb -o report.html --log-format=COMBINED
Provyzor commented 1 year ago

Thanks a lot!

Provyzor commented 1 year ago

Added on more record with ASN-database to goaccess.conf, nothing changed:

geoip-database /usr/local/share/GeoIP/GeoLite2-City.mmdb geoip-database /usr/local/share/GeoIP/GeoLite2-ASN

allinurl commented 1 year ago

is that an mmdb file?

Provyzor commented 1 year ago

Wow! It works!!

Sorry, the file extension missed in config file!

Respect and uvazhuha (something like respect in Russian) to you! 👍

allinurl commented 1 year ago

@Provyzor glad that worked! thanks for the kind words as well :)

Closing this, feel free to reopen it if needed.