Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

New Member

Content rules / redirect dynamic url CSS11501

All,

I have a css11501 and I have a situation where there are 2 servers in disparate datacenters, that I would like to balance requests to, based on URL requested - using http redirects.

Clients come in and request http://X.X.X.X:4100/blah/whatever.aspx?foo=bar

I want to redirect requests to X.X.X.X on port 4100 that contain /blah/whatever.aspx and http redirect them to Y.Y.Y.Y:4100 and Z.Z.Z.Z:4100 preserve the rest of the request (/blah/whatever.aspx?foo=bar). Can I do this? The args passed to whatever.aspx are dynamic -- I just want to http redirect to a couple of different servers, and preserve the entirety of the request, changing only the destination IP.

How could I do this?

Thanks,

-wP!

2 REPLIES
Silver

Re: Content rules / redirect dynamic url CSS11501

Cisco Employee

Re: Content rules / redirect dynamic url CSS11501

do you really need an http redirect ???

The way it normally works is that the CSS will listen on x.x.x.x port 4100 and loadbalance between the 2 servers y.y.y.y and z.z.z.z.

When forwarding the traffic to the servers, the CSS will replace the initial destination ip x.x.x.x with one of the server's ip without changing the content of the data.

This is the default behavior.

There is nothing special to do.

You have to make sure that the server response comes back to the CSS. You can do this by adjusting your routing table on every device between css and servers, or you can have the CSS nat the client ip address with one of its own.

Here is a sample config

service srv1

ip address y.y.y.y

active

service srv2

ip address z.z.z.z

active

owner MyCompany

content Application1

vip address x.x.x.x

proto tcp

port 4100

add service srv1

add service srv2

active

That's all for the first part.

If you need client nat you add the following

group ClientNat

vip address x.x.x.x

add destination service srv1

add destination service srv2

active

Done. !

Gilles.

198
Views
0
Helpful
2
Replies
CreatePlease login to create content