Forum Discussion
ingard
Nimbostratus
Jan 25, 2016irule to log slow and/or tcp profile timed out requests to backend
Hi
I'm trying to identify which requests are causing our backends to stop responding/hang/fail.
I was thinking some sort of timer and/or catch the tcp timeout rst maybe? I've been trying to figu...
Kai_Wilke
MVP
Jan 25, 2016Hi Ingard,
unfortunately there is no way to access TCP flags (PSH, RST, etc.) using iRules.
But you may try this snipped as a starting point to identify slow server responses...
when RULE_INIT {
set static::timeout 10000 ; msec
}
when HTTP_REQUEST {
set debug(request_url) "[HTTP::host][HTTP::uri]"
set debug(id) [after $static::timeout {
log local0.warn "$static::timeout msec timeout reached for \"$debug(request_url)\""
}]
}
when HTTP_RESPONSE {
after cancel $debug(id)
unset -nocomplain debug
}
when CLIENT_CLOSED {
if { [info exist debug(request_url)] } then {
log local0.warn "Connection closed without HTTP response for \"$debug(request_url)\""
}
}
Cheers, Kai
- JRahmDec 20, 2022
Admin
FYI Kai_Wilke, you can access the TCP flags in the FLOW_INIT event with the DATAGRAM::tcp flags command.
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