Forum Discussion

Thanadon_Wattan's avatar
Thanadon_Wattan
Icon for Nimbostratus rankNimbostratus
Jul 06, 2005

Can i-Rule use pool to map to virtual server?

Hi all, I'm newbie in F5 v.9. I'm facing with some problem about Virtual Server.

 

 

I have 2 VS in F5 10.10.10.30 and 10.10.20.30 and both using the different pool (named pool01 and pool02 in the same subnet of each VS relatively).

 

 

the problem occurs when I try to create another pool (called pool03 that have 1 member that is 10.10.20.30 <== this is VS IP of the second VS).

 

 

I try to mapping if the request uri is /web I write in i-rule like this:

 

 

request_uri [HTTP::uri]

 

if {(request_uri starts_with "/web")} {

 

pool pool03

 

}

 

 

when I request to /web , nothing is returned.

 

what's wrong? or Can the i-rule forward the request to another VS?

 

 

Thank you in advance for any idea comment or answer.

3 Replies

  • Try this:

     
     when HTTP_REQUEST { 
       if { [HTTP::uri] starts_with "/web" } { 
         use pool pool03 
         } 
       } 
     

    If this doesn't work you might try logging before your if statement to make sure the uri actually contains the string you're trying to match.

    log "The URI is [HTTP::uri]"
  • drteeth_127330's avatar
    drteeth_127330
    Historic F5 Account
    No. A pool cannot contain a virtual server as a member. Why not redirect back to the virtual server instead?

     

     

    Incidentally, this feature will be added in a future release. I should also mention that with a vlangroup configuration, a virtual server can have the same IP address as a pool member, but this is not the same thing.