Forum Discussion

wassim_97659's avatar
wassim_97659
Icon for Nimbostratus rankNimbostratus
Feb 18, 2011

IRule redirect to WIDE IP

Hey guys,

 

 

On GTM 1600 running BIGIP-10.2.0, I want to redirect requests from a subnet to a wide IP that is already configured on my GTM box also. I know I can add the code1 below so GTM return a CNAME to clients and then the client sends another request to my GTM box for the new name. Is there a way so that the GTM redirects the request directly to the wide IP instead of sending back the cname as in code2. The idea here is to reduce the load on the GTM box.

 

 

 

code1:

 

when DNS_REQUEST {

 

if {[IP::addr [IP::client_addr]/24 equals 10.10.10.0/24]} {

 

cname "something.com"} else {

 

cname "anotherthing.com"}

 

}

 

 

Code2: (notworking, but is it possible??)

 

when DNS_REQUEST {

 

if {[IP::addr [IP::client_addr]/24 equals 10.10.10.0/24]} {

 

wideip name "something.com"} else {

 

wideip name "anotherthing.com"}

 

}

 

 

 

Thanks

1 Reply

  • Am looking at the available commands and not seeing anything stick out.

     

     

    http://devcentral.f5.com/wiki/default.aspx/iRules.GTM

     

     

    You can obviously use "host" to send them directly to an IP address. You could also use "pool" I suppose.