cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
887
Views
0
Helpful
5
Replies

http redirect

rich.polyak
Level 1
Level 1

Good day, I'm hoping someone can assist. I have the Web Admins reqeusting that they want the users to be able to just put in there browser http://www.company.com and then automatically be transfered to http://www.company.com/site_a. Currently this is the content rule I have setup.

service ws1

ip address x.x.x.10

keepalive port 80

keepalive type http

redundant-index 20195

keepalive uri "/site_a/start.swe?SWECmd=Start&SWEHo=ws1"

active

service ws2

ip address x.x.x.11

keepalive port 80

keepalive type http

redundant-index 20195

keepalive uri "/site_a/start.swe?SWECmd=Start&SWEHo=ws2"

active

content site_a

redundant-index 20195

add service ws1

add service ws2

vip address x.x.x.4

advanced-balance sticky-srcip

protocol tcp

port 80

url "//www.company.com/*"

active

What would I need to do to change or add inorder for all requests matching the following http://www.company.com/site_a to be redirected to http://www.company.com ?

I do not prefer to utilize service redirectes unless it's back through the content switch. Will the content redirect work for what I'm asking? If so how do I format the content rule?

Thx

-Rich

5 Replies 5

Gilles Dufour
Cisco Employee
Cisco Employee

http://www.cisco.com/en/US/products/hw/contnetw/ps789/products_configuration_example09186a00801de8d6.shtml

Based on the link above, all you need to do is add the following content rule

content redirect_site_a

vip address x.x.x.4

protocol tcp

port 80

url "//www.company.com/"

redirect "//www.company.com/site_a"

active

Thanks for the quick reply,

So I do not need another css rule? In the content rule just add the redirect string to the content rule.

That would be a great help.

Thx

One more question, Since I'm redirecting to a page off of the primary content rule, all CSS load balancing decisions will still come into play?

Thx

you need to create a new rule.

Read my example carefully.

The content rule name is different

I call it redirect_.... and the url is also different - there is no "*" at the end.

Just add the new rule exactly as I sent it.

It will intercept all http request for the default site "/" and redirect it to site_a.

The client will submit a new request for site_a and it will match your first rule.

Gilles.

Gilles,

Thanks for the clairifaction, After i reread the post I understood exactly what you meant. Again Thanks for the help.