Measuring bytes of packet sent from python application

Kangkook Jee aixer77 at gmail.com
Mon Jan 5 17:26:06 EST 2009


Hi, all

I'd like to measure number of bytes sent(or recv'd) from my python
application. Does anyone have any idea how can I achieve this?

I tried to do this by tracing some socket calls (send, sendto, sendAll) 
  using 'metaclass' but I could find exactly place that I can put this in.


My application runs some number of protocols (bittorrent, xmlrpc ..) in
it and will be measured for a couple of hours.

Thanks a lot for your help, in advance
/Kangkook



More information about the Python-list mailing list