Forum Discussion

smiley_dba_1116's avatar
smiley_dba_1116
Icon for Nimbostratus rankNimbostratus
Nov 05, 2012

iRule redirect to pool that meets this URI

Need some help here. The general jist is that when a packet comes in that says www.abc.com/search, go to this pool2, but otherwise, go to pool1. The reason I put the whole URI is because multiple websites live in this VS.

 

 

 

client----abc.com/search----->VS=192.192.192.92 ----------->Pool1---->Members

 

|

 

|------->Pool2----->Members

 

 

How would I present this in a iRule?

 

 

RGW

 

1 Reply

  • nathe's avatar
    nathe
    Icon for Cirrocumulus rankCirrocumulus
    RGW

    How about:

    when HTTP_REQUEST {
      if { [HTTP::uri] starts_with "/search" } {
        pool pool2
      } else {
        pool pool1
      }
    } 

    Rgds,

    N