This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Tcp tapping


On 5/14/10 12:44 PM, "William Cohen" <wcohen@redhat.com> wrote:
> 
> These are very useful locating things in the kernel.You can look to see what
> calls
> sk_stream_wait_memory() and the conditions that trigger those calls.
> 
> In linux 2.6.33 you can see that the call to sk_stream_wait_memory() occurs in
> net/ipv4/tcp.c in a couple places:
> 
> http://lxr.linux.no/#linux+v2.6.33/net/ipv4/tcp.c#L841
> http://lxr.linux.no/#linux+v2.6.33/net/ipv4/tcp.c#L1090
> 
> Then you should be able to find which elements of the struct sock hold the
> information triggering the sk_stream_wait_memory().

Cool, I got this working to print out the size of the send and the size of
the kernel socket buffer and how much is queued.

Does anyone have any idea where in the code to try and print out TCP
receives (the size of the buffer and how much data is in the buffer)?  The
idea is to visualize the receive buffer as it gets full and is emptied out.

Cheers,
> Ivan


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]