cancel
Showing results for 
Search instead for 
Did you mean: 

Resolv lookup by virtual server name

gabigart_31229
Nimbostratus
Nimbostratus

Hi!

 

We are trying to resolve some domains using the RESOLV::lookup command on iRules, so we created a virtual server pointing to a pool of DNS servers.

 

The code we use in the iRule is as follows:

 

set ips [RESOLV::lookup @vserver_dns -a $host]

 

 

But when running, we get the following error message:

 

Tue Jul 31 17:23:17 EDT 2012 err tmm tmm[7060] 01220001 TCL error: /Common/suppliers - while executing "RESOLV::lookup @vserver_dns -a $host"

 

 

So we were needing help to see what we are doing wrong.

 

4 REPLIES 4

Mohamed_Lrhazi
Altocumulus
Altocumulus
the wiki says this was added in BIGIP 10.1, what version are you running?

 

 

https://devcentral.f5.com/wiki/irules.resolv__lookup.ashx

 

hoolio
Cirrostratus
Cirrostratus
Can you try setting the virtual server name with the folder:

 

 

set ips [RESOLV::lookup @/Common/vserver_dns -a $host]

 

 

Aaron

nitass
F5 Employee
F5 Employee
Aaron is correct. :)

 

 

[root@ve11a:Active:Changes Pending] config tmsh root@(ve11a)(cfg-sync Changes Pending)(Active)(/Common)(tmos) list ltm rule myrule ltm rule myrule { when HTTP_REQUEST { log local0. [RESOLV::lookup @/Common/dnsvs -a "www.google.com"] } } [root@ve11a:Active:Changes Pending] config tail -f /var/log/ltm Oct 19 20:28:15 tmm info tmm[23647]: Rule /Common/myrule : 173.194.38.146 173.194.38.144 173.194.38.148 173.194.38.145 173.194.38.147

gabigart_31229
Nimbostratus
Nimbostratus

Aaron, thank you very much!

 

It would be great to update documentation at https://devcentral.f5.com/wiki/iRules.resolv__lookup.ashx :p

 

 

Thanks!