Forum Discussion

Powik_208795's avatar
Powik_208795
Icon for Nimbostratus rankNimbostratus
Jan 10, 2017

Local Traffic Policy redirect traffic to Pool and Pool Member

Hi,

 

It's possible with Policy to redirect traffic to a specifit pool member of a pool.

 

Example iRule:

 

when HTTP_REQUEST { switch -glob [HTTP::uri] { "/xxx" { pool pool_xxx node 10.10.10.10 8080 } "/yyy" { pool pool_yyy node 20.20.20.20 8080 }

 

} }

 

Thanks in advance for your help.

 

2 Replies

  • hi Eloy, I think, you should apply this irule;

    when HTTP_REQUEST { 
        switch -glob [HTTP::uri] {
            "/xxx" { 
                pool pool_xxx member 1.1.1.1 80
                } 
            "/yyy" { 
                pool pool_yyy member 1.1.1.1 80
                }   
    } 
    }
    
  • if { [HTTP::uri] eq "/xxx" } { pool pool_xxx member 20.20.20.20 8080 }

     

    Then by all means expand with if/else conditions.