For more details, please see ourCookie Policy.

Application Delivery (ADX)

Occasional Contributor
Posts: 6
Registered: ‎03-17-2010

ADX using Code Router, Source-Nat-ip and CSW not working

Hello people interesting:

I have a big problem. I have a ADX configured in the following scenario:

1. - ADX with router firmware, is applying Nat-ip Source with code 12.400j

2. - Balancing is performed on an application ASP.Net

3. - Balancing is on two servers: A real server and a remote server.

4. - The ADX is on the Real Server network.

5.- - Balancing work if not applied CSW.

However, when I apply Content Switching on the response of Server (Set-Cookie), as well as the host header (request) and the cookie sticks to the client is not working. How I can apply a suitable persistence? What am I doing wrong?

server port 80

server source-nat-ip  port-range 2


context default


csw-rule "rule1" response-header "Set-Cookie" pattern "ASP.NET_SessionId="

csw-rule "rule2" header "Host" equals ""

csw-rule "rule3" header "Cookie" pattern "ASP.NET_SessionId="


csw-policy "policy1"

match "rule1" passive-persist offset 0 length 7 

match "rule3" persist offset 0 length 7 passive-persist

match "rule2" persist offset 0 length 7 passive-persist


server real real1                   


port 8081

port 8081 keepalive

port 8081 server-id 1024

port 8081 group-id  1 1


server remote-name remote1


port 8082

port 8082 keepalive

port 8082 server-id 1025

port 8082 group-id  1 1



server virtual          

sticky-age 5

predictor response-time

port http sticky concurrent

port http csw-policy "policy1"

port http csw

port http keep-alive

bind http real1 8081

bind http remote1 8082


ip default-network

ip dns domain-name

ip dns server-address

ip route



interface ethernet 10


ip address



Former Brocadian
Posts: 100
Registered: ‎01-13-2009

Re: ADX using Code Router, Source-Nat-ip and CSW not working

Hi ajuarez,

I asked around and got a couple pieces of advice for you.

Either remove or modify “rule2” from the csw-policy. It doesn’t make sense to use host header for passive persistency. If you want, you can try modifying it to the following first and then removing it if it doesn't work out.

csw-rule "rule2" url pattern "ASP.NET_SessionId="

If it doesn’t resolve the problem, then perhaps try some debugging, using “url debug” as follows:

rconsole virtual

url debug 1 <client PC IP address>

--->then generate problematic traffic

-> to stop debugging, “url debug 0” and “rconsole-exit”.

And check the outputs.

Join the Broadcom Community

Get quick and easy access to valuable resources across the Broadcom Community Network.