The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Special Forums > IP Networking
.
google unix.com



IP Networking Learn TCP/IP, Internet Protocol, Routing, Routers, Network protocols in this UNIX and Linux forum.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
reduce used paging space bfarah AIX 1 07-21-2008 05:21 AM
disk space kingsto88 Filesystems, Disks and Memory 3 12-06-2006 05:28 AM
Disk space? jbarbuto SUN Solaris 4 08-18-2004 07:58 AM
available disk space on disk device??? alan UNIX for Dummies Questions & Answers 4 01-02-2004 03:06 AM
Out of disk space? alfabetman UNIX for Dummies Questions & Answers 4 10-03-2001 03:57 AM

Reply
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 07-02-2009
Calimero90's Avatar
Calimero90 Calimero90 is offline
Registered User
  
 

Join Date: Jul 2009
Location: france
Posts: 1
tcpdump -w: how to reduce disk space ?

Hello !

I am using
tcpdump -w /tr.cap -p -n -s 0 "udp"
to trace my network trafic.
(analysing later)

I want to reduce the size of the trace files.
Firtst i can use the great -C option but old files are not deleted...
Second I don't want trace RTP packet but i can't find how to use ("not rtp" , "udp.port < 10000"...)

Idealy i want trace only few firsts bytes of RTP but all bytes of other...

Any idea ?
Thanks
  #2 (permalink)  
Old 07-07-2009
gratuitous_arp gratuitous_arp is offline
Registered User
  
 

Join Date: Jul 2009
Posts: 7
A few ideas:

If you're happy with what you're doing except that you also want to delete old files, use a cron job or script that runs every 10 seconds (or whatever) and deletes any file (which must at least partially match the name you specify with the -w switch) exceeding the number of Bytes you entered for the -C parameter for tcpdump.

You can use the "dst portrange" qualifier to search for packets with destination ports not exceeding 9999 (i.e., tcpdump -i eth0 dst portrange 0-9999).

If you have some script that reads these files in and parses them for information then deletes them, you could save yourself the bother of writing a file, and instead use tcpdump's -l option to enable line buffering. This will let you pipe the output of tcpdump directly into a command(s) for parsing.

Good luck.
Sponsored Links
Reply

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 10:50 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language translation by Google.
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0