how do you specify a string with advanced-balance url?

Unanswered Question
Apr 29th, 2008

I am trying to configure a CSS 11501 to send requests with a specific string in the URL to a specific server. How and where I would specify the string? The documentation, as far as I can tell, mentions that it can be done but does not show how. Any input is greatly appreciated.

I have this problem too.
0 votes
  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 4.5 (2 ratings)
Loading.
Syed Iftekhar Ahmed Tue, 04/29/2008 - 16:14

service www1

ip address x.x.x.1

string Server1

active

service www1

ip address x.x.x.2

string Server2

active

content test

add service test

vip address z.z.z.z

protocol tcp

port 80

url "/*"

advanced-balance url

string prefix "goto="

string range 1 to 1000

string process-length 6

active

Syed

eleibowitz Wed, 04/30/2008 - 07:16

Syed, thanks for the quick response. If I understand this correctly, the CSS will look for the strings "Server1" or "Server2" in the URL, within 1000 bytes after "goto=". Is that correct? The documentation is not clear on the 'string process-length' command, so can you possibly explain that?

Thanks again,

Eliot

Syed Iftekhar Ahmed Wed, 04/30/2008 - 09:48

CSS will look for the server id within 1000 bytes (string range 1 to 1000 --- By defaukt CSS looks into first 100 bytes)

It will look for the string prefix (goto=) and then string process-length command is used to find the server ID after the prefix (how many bytes-- 6 in this case, after the end of prefix designated by the string prefix)

eleibowitz Thu, 05/01/2008 - 12:35

Thanks again, Syed. Now it makes sense, but I was digging more into the documentation and found a simpler way to accomplish this.

service webServer1

ip address 10.1.1.1

keepalive type http

active

service webServer2

ip address 10.1.1.2

keepalive type http

active

content webServers

add service webServer1

add service webServer2

balance aca

vip address 10.2.2.1

protocol tcp

active

content fileServer

add service webServer1

vip address 10.2.2.1

protocol tcp

url “/files/*”

active

The idea being that most requests will get load-balanced between both web servers, but if the URL starts with "/files/", then only webServer1 will receive the requests.

Actions

This Discussion