cancel
Showing results for 
Search instead for 
Did you mean: 

Outstanding request per virtual server

Ravindra
Nimbostratus
Nimbostratus

How can we get outstanding request in F5 virtual server like number of request received, number of request processed and number of request pending ?

 

1 REPLY 1

Kai_Wilke
MVP
MVP

Hi Ravindra,

 

you may take a look to the Virtual Server statistics. For HTTP traffic you will get independent counters for HTTP requests / responses...

 

(tmsh) show ltm virtual VS_MyVirtualServer profiles raw

Beside of this rather simple functionality you could also deploy some iRules on your Virtual Servers which are counting the individual request/response numbers of a given time-frame by using [table -subtable] entries.

 

when RULE_INIT { set static::statistic_lifetime 10 ; Seconds } when HTTP_REQUEST { if { [HTTP::path] eq "/show_stats" } then { set http_response " Requests: [table keys -subtable "[virtual]_request_counter" -count] Pending: [table keys -subtable "[virtual]_pending_counter" -count] Response: [table keys -subtable "[virtual]_response_counter" -count] " HTTP::respond 200 content $http_response "Content-Type" "text/html" "Connection" "close" return } Initialize request ID label set request_id "[TMM::cmp_unit][clock clicks]" Update requests and pendings table set -subtable "[virtual]_request_counter" $request_id indef $static::statistic_lifetime table set -subtable "[virtual]_pending_counter" $request_id indef $static::statistic_lifetime } when HTTP_RESPONSE { Update responses and remove pendings table set -subtable "[virtual]_response_counter" $request_id indef $static::statistic_lifetime table delete -subtable "[virtual]_pending_counter" $request_id }

Cheers, Kai