Forum Discussion

mani_85876's avatar
mani_85876
Icon for Nimbostratus rankNimbostratus
Apr 03, 2009

NAME::response does not contain any A record responses

Could you please suggest how to solve this?

 

Issue

 

=====

 

In the NAME_RESOLVED event I am not getting the response IP address (see below for the snippet I copy pasted from local traffic log file).

 

Background

 

=========

 

I wrote a simple iRule that does address record lookup. I am following the sample here http://devcentral.f5.com/wiki/default.aspx/iRules/DestinationSnatUsingDNS.html

 

I verified the following:

 

1)/config/tmm_base.tcl has this section.

 

proxy RESOLV {

 

use server $IP_ADDR_LOCALHOST $service(domain)

 

serverside UDP

 

}

 

2) I also, had turned on recursive queries on in named.conf as mentioned in the link.

 

3) I also restarted by running the command – “bigstart restart tmm”

 

4) I added my dns server by running the command "bigpipe dns nameservers n.n.n.n"

 

5) I logged on to BigIP/F5 shell and verified the "dig n.n.n.n.testdomain.net +short" returns expected A response.

 

 

Here is my iRule

 

================

 

when CLIENT_ACCEPTED {

 

log local0. "Remote address is [IP::remote_addr]"

 

log local0. "dig for [IP::client_addr].testdomain.net"

 

NAME::lookup "[IP::client_addr].testdomain.net"

 

}

 

when NAME_RESOLVED {

 

log local0. "response name [NAME::response name]"

 

log local0. "IP address list = >[NAME::response]<"

 

log local0. "index0 [lindex [split [NAME::response] " "] 0]"

 

log local0. "index1 [lindex [split [NAME::response] " "] 1]"

 

log local0. "index2 [lindex [split [NAME::response] " "] 2]"

 

log local0. "index3 [lindex [split [NAME::response] " "] 3]"

 

}

 

Copy pasted snippet from (Local0)Local traffic log file:

 

========================================================

 

Fri Apr 3 10:15:43 PDT 2009 tmm tmm[1350] Rule sen_dns_test NAME_RESOLVED: index3

 

Fri Apr 3 10:15:43 PDT 2009 tmm tmm[1350] Rule sen_dns_test NAME_RESOLVED: index2

 

Fri Apr 3 10:15:43 PDT 2009 tmm tmm[1350] Rule sen_dns_test NAME_RESOLVED: index1

 

Fri Apr 3 10:15:43 PDT 2009 tmm tmm[1350] Rule sen_dns_test NAME_RESOLVED: index0

 

Fri Apr 3 10:15:43 PDT 2009 tmm tmm[1350] Rule sen_dns_test NAME_RESOLVED: IP address list =

 

Fri Apr 3 10:15:43 PDT 2009 tmm tmm[1350] Rule sen_dns_test NAME_RESOLVED: response name 157.55.168.101.testdomain.net

 

Fri Apr 3 10:15:43 PDT 2009 tmm tmm[1350] Rule sen_dns_test CLIENT_ACCEPTED: dig for 157.55.168.101.testdomain.net

 

Fri Apr 3 10:15:43 PDT 2009 tmm tmm[1350] Rule sen_dns_test CLIENT_ACCEPTED: Remote address is 157.55.168.101

2 Replies

  • Which LTM version are you running? If you run a tcpdump filtering for the name server IP address, do you see any packets being sent/received?

     

     

    Aaron
  • Thanks Aaron

     

    1) tcpdump shows F5-dns traffic when I do a dig n.n.n.n.testdomain.net +short. However, I dont see any traffic when the iRule is invoked. Could you please suggest what else I need to look at to resolve this issue.

     

     

    2) This is on LTM version 9.4.4.

     

     

    General Properties show these:

     

    -------------------------------------------

     

    Version BIG-IP 9.4.4 Build 65.1 Final

     

    CPU Count 1

     

    Active CPUs 1

     

    CPU Mode Uniprocessor