Hi, I have log lines from an IPv4 network.
However, in the log lines some of the IP addresses are mapped toIPv6, i.e. are in IPv6 format.
I wonder if there's a good way for those addresses to be converted to IPv4 format.
Example of IPv4 address mapped in IPv6:
::ffff:a00:6
If you use any online converter, you'll notice that this address translates to the following IPv4 address:
10.0.0.6
I have no issue parsing the addresses since I can use multiple grok filters with %{iPV6:srcIPv6} and %{IPV4:srcIPv4} pattern types.
My ask is around how to convert the IPv6 format into an IPv4 one (same as the tool does).
I've seen in some posts (example 1) where the use of a ruby filter is recommended.
Would appreciate your help.
I've used a workaround using [geoip][ip] but I think I'm paying a high computational price for IPv6-to-IPv4 conversion.
The error that I'm getting in logstash's logs, because of this, is:
[2018-12-01T17:34:13,309][ERROR][logstash.filters.ruby ] Ruby exception occurred: Missing Converter handling for full class name=org.jruby.RubyObjectVar2, simple name=RubyObjectVar2
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.