Sep 24, 2008
Please help - can't understand error in this case
Very simple irule, basically I want to send to one of two pools based on some criteria.
In parsing, I get an error:
line 5: [parse error: PARSE syntax 192 {syntax error in expression " ([HTTP::host] contains "abc.xyz.com") && ([HTTP::cookie] ...": looking for close parenthesis}]
and:
line 8: [undefined procedure: else] [else {
pool test-old
the code looks like:
when HTTP_REQUEST {
if { ([HTTP::uri] contains "a.m") || ([HTTP::uri] contains "b.m")} {
pool test-new
}
elseif { ([HTTP::host] contains "abc.xyz.com") && ([HTTP::cookie] exists "cookieid")} {
pool test-new
}
else {
pool test-old
}
}
Sorry to post something so basic, but I've been staring at this for an hour and see all the parends I think are required and am totally stumped by the else error on line 8.
TIA to all!