Forum Discussion
Anjlica_110059
Nimbostratus
Aug 09, 2007iRule closes connection
I modified the original question after I realised CLIENT_CONNECTED is not the right state to use inthe iRule when no connections exist.
------------------------------------------------
...
Anjlica_110059
Nimbostratus
Aug 09, 2007Here is the set up we have -
There are several servers each listening on multiple ports.Several client machines run the client application.
Client application is started.
Client opens x number of sockets using a VIP and port.
We want number of new sockets opened to be round robbin load balanced between diff. servers and ports.
The client logs into each server and starts sending requests(PSH,ACK) over existing connections.
So if client has an existign connection with server x port y, then we want that request to go to that server and port combination.
Since we have several client machines connecting to same set of servers, we cannot use source ip address persistence.
We almost got to a point where the script seem to follow the right path(we are still printintg out to logs to see if the right event gets triggered):
when CLIENT_ACCEPTED {
TCP::collect 6
log local0. "HERE 1"
}
when CLIENT_DATA {
set payload_string [TCP::payload]
log local0. "data [TCP::payload]"
if {$payload_string contains "LOGIN"} {
pool mypool
log local0. "new"
} else {
log local0. "HERE 2"
set src_ip_and_port [TCP::client_port]
log local0. "src port <$src_ip_and_port>"
if { $src_ip_and_port != "" } {
log local0. "persist"
} else {
log local0. "error1"
}
}
TCP::release
}Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects