cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
671
Views
0
Helpful
3
Replies

URL-Redirection using ACE

dinesh1977
Level 1
Level 1

Hi,

when a user hit a VIP with particular url string,can i redirect that url to another VIP ?

1.EG: 10.10.10.1/crm ,has to redirect to another VIP 10.10.10.10.

2. 10.10.10.1/erp , has to redirect to another VIP 10.10.10.20.

Will it possible in ACE ?

3 Replies 3

Gilles Dufour
Cisco Employee
Cisco Employee

you can creat an http redirect message and have it sent to the client based on the url requested.

The client will then come back to the new url provided in the redirected.

However, why use a redirect ?

Can't you just map the specific url to a specific serverfarm that would be different depending on the url ?

You avoid the delay of sending the redirect and waiting for the client to reopen a connection to the appropriate vip.

Gilles.

Hi Gillies

thanks for the reply ..

1 .suppose when a user accessing particular url using the VIP 10.10.10.1/crm . This request has to go to another VIP 10.10.10.10 , where i will bound the real servers which is running those services .

2.suppose when a user accessing particular url using the VIP 10.10.10.1/ERP . This request has to go to another VIP 10.10.10.20 , where i will bound the real servers which is running those services .

How to map the specific url to a specific serverfarm ?

If you have any sample scripts for this , please send to me .. It will be very helpful . ( I don't have that much exposure in ACE ) .

Once again thanks for your support

Here is an example.

All traffic matching /crm will go to linux1, traffic matching /erp will go to linux2 and all the rest will go to server 3.

No need for redirect.

class-map type http loadbalance match-any url-crm

2 match http url /crm.*

class-map type http loadbalance match-any url-erp

2 match http url /erp.*

class-map match-all vip-192.168.20.21

2 match virtual-address 192.168.20.21 tcp eq 80

policy-map type loadbalance first-match url-select

class url-erp

serverfarm linux1

class url-crm

serverfarm linux2

class class-default

serverfarm linux3

policy-map multi-match SLB1

class vip-192.168.20.21

loadbalance vip inservice

loadbalance policy url-select

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: