Having problem in reverse mapping of hostname to ip address using DNS filter

I am trying to use the DNS filter to map the hostname to IPaddress , below is the sample configuration I tried to map google.com to ipaddress

filter{
    mutate {
    add_field => {"hostname", "google.com"}
    }
   
   dns {
   reverse => ["hostname"]
   action => "replace"
   nameserver => ["8.8.8.8", "8.8.4,4"]
   timeout => 10.0 #Just to make sure timeout is not the problem here
   }
}

the hostname does not translate to ip address , let me know what i am doing wrong here

You have it the wrong way around...

reverse takes an IP address and looks up its name.
resolve takes a name and looks up its IP address.

1 Like

Thanks a lot

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.