tcpdump mailing list archives

Re: how to get total packets length by tcpdump


From: Christian Kreibich <christian () whoop org>
Date: Mon, 08 Mar 2004 22:33:32 +0000

Hi,

On Mon, 2004-03-08 at 22:08, wcai () gmu edu wrote:
Greetings,

Is there any simple way to calculate the total length (in bytes) of  all tcp packets in a tcpdump file? I mean, is it 
possible that I can do this by adding some options to tcpdump?

I can't think of a way to do this directly using tcpdump. Netdude has a
traffic analyzer plugin that gives you protocol usage statistics easily
-- have a look at http://netdude.sf.net. Here's some sample output:

# IP PROTOCOL ANALYSIS:
# =====================
#
# Aggregates packets and bytes per IP protocol payload type.
# proto number -- #packets -- #bytes -- %packets -- %bytes

1       2122    1831886 11.26   27.54
17      3948    617773  20.95    9.29
6       12773   4203113 67.79   63.18

(IP protocol 6 is TCP) If this is what you need, you're welcome to get
in touch and I'll give you more details.
 
Hope this helps,
Christian.
-- 
________________________________________________________________________
                                          http://www.cl.cam.ac.uk/~cpk25
                                                    http://www.whoop.org


-
This is the TCPDUMP workers list. It is archived at
http://www.tcpdump.org/lists/workers/index.html
To unsubscribe use mailto:tcpdump-workers-request () tcpdump org?body=unsubscribe


Current thread: