Forum Discussion

jcook_105986's avatar
jcook_105986
Icon for Nimbostratus rankNimbostratus
Aug 20, 2008

how do i get the active connection stat?

 

When I said "active connection stat"; by I mean,

 

I need to find out the total number of conections to the server.

 

 

Not the number of connection to one of the pool members...

 

Not the number of connection to one of the virtual server...

 

Im talking about the number of whole connection to F5 server itself.

 

 

Is there any API that gives such information?

 

 

 

 

Thank you in advance.

2 Replies

  • Hamish's avatar
    Hamish
    Icon for Cirrocumulus rankCirrocumulus
    Yep. Either via iControl, or SNMP. From memory it's in the systemStats. e.g.

     
        my $System = SOAP::Lite  
             -> uri('urn:iControl:System/Statistics')  
             -> proxy("$sProtocol://$icUser:$icPass\@$icServer:$icPort/iControl/iControlPortal.cgi", cookie_jar => $cookieJar);  
        
        my($now)       = time();  
        
        my $soapResponse = $System->get_global_statistics();  
        my ($status, $text)=&checkResponse($soapResponse);  
        $GlobalStatList = $soapResponse->result;  
        my $soapResponse = $System->get_http_statistics();  
        my ($status, $text)=&checkResponse($soapResponse);  
        $HTTPStatList = $soapResponse->result;  
        my $soapResponse = $System->get_client_ssl_statistics();  
        my ($status, $text)=&checkResponse($soapResponse);  
        $clSSLStatList = $soapResponse->result;  
        
     

    Which gives you 3 references $GlobalStatList $HTTPStatList $clSSLStatList which should give up al the stats you'd love to see. Including total connections.

    H
  • Don_MacVittie_1's avatar
    Don_MacVittie_1
    Historic F5 Account
    Hamish has it. Just in case you're not using Perl, the Wiki Document for System::get_global_statistics() is here:

     

     

    http://devcentral.f5.com/wiki/default.aspx/iControl/System__Statistics__get_global_statistics.html

     

     

    Don.