Using the GeoIP2 parser
Declaration:
In the following example, AxoSyslog retrieves the GeoIP2 data of the IP address contained in the ${HOST} field of the incoming message (assuming that in this case the ${HOST} field contains an IP address), and includes the data (prefixed with the geoip2
string) in the output JSON message.
For example, for the <38>2017-05-24T13:09:46 192.168.1.1 prg00000[1234]: test message
message the output will look like:
Last modified July 2, 2023: Change highlight mode of code examples (2f8a959)