Forum Discussion
Aug 11, 2010
Need to log pool member selected
I need some ideas on the best way to log the pool member selected during a connection. The user is under the impression x-forwarded will solve their problem... We're not using SNAT here so we're al...
Chris_Miller
Aug 11, 2010Altostratus
Posted By hoolio on 08/11/2010 10:12 AM
You can do this in the HTTP_REQUEST_SEND event:
when HTTP_REQUEST_SEND {
Need to force HTTP:: commands into the clientside context as the
HTTP_REQUEST_SEND event is in the serverside context
clientside {
Insert a custom HTTP header in the request headers with the selected server IP
HTTP::header insert Selected-Server [LB::server addr]
}
}
You could use just [LB::server] to get the pool name, IP and port instead of just the member IP with [LB::server addr].
Aaron Nice Aaron! Is there a list somewhere that has the order in which the iRule events are processed? Obviously LB::server addr wouldn't be valid until the member is chosen...so does this get executed right after LB::selected?
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