Forum Discussion
rahtoll_74678
Nov 07, 2012Nimbostratus
Hi Guys,
Just an update, below irule seems to have done what i need, though more tests to confirm, thanks Nitass and Steve (option 3 worked)...
when CLIENT_ACCEPTED {
TCP::collect
}
when CLIENT_DATA {
set mero [TCP::payload 11]
Start reading at the 5th byte and save 6 characters to $match
if {[binary scan $mero x5a6 match] == 1}{
log local0. "PAYLOAD Matched $match"
if { $match eq "000001" } {
log local0. "PAYLOAD $match goes to Pool 1"
log local0. $match
LB::detach
pool Pool1
log local0. "Finished choosing POOL 1"
TCP::release
} else {
log local0. "PAYLOAD $match goes to Pool 2 "
LB::detach
pool Pool2
log local0. "Finished choosing POOL 2"
TCP::release
}
}
TCP::release
TCP::notify request
TCP::collect
}