LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 10-18-2010, 03:59 PM   #1
greyarea
LQ Newbie
 
Registered: Jan 2008
Distribution: Centos5/RHEL5
Posts: 18

Rep: Reputation: 0
tcpdump -w not writing data


Hi

I'm trying to capture packets to a file with the -w option but the file is empty yet if I use the '-w -' option to put data on stdout I see plenty of captured packets.

I'm using CentOS 5.5 x86

Code:
[root@server ~]# tcpdump -v -i eth0 -w dump -s0
tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 65535 bytes
718 packets captured
718 packets received by filter
0 packets dropped by kernel
[root@server ~]# file dump
dump: empty
Any ideas why the file is empty?

Ta,
 
Old 10-18-2010, 04:16 PM   #2
rweaver
Senior Member
 
Registered: Dec 2008
Location: Louisville, OH
Distribution: Debian, CentOS, Slackware, RHEL, Gentoo
Posts: 1,833

Rep: Reputation: 163Reputation: 163
Is the drive full and do you have write permissions to the directory (check chattr for special perms also)? Also see if it writes them to screen if you use a -w -
 
Old 10-18-2010, 04:35 PM   #3
greyarea
LQ Newbie
 
Registered: Jan 2008
Distribution: Centos5/RHEL5
Posts: 18

Original Poster
Rep: Reputation: 0
I can create files in root's home directory without a problem, plenty of space on the slice. And yes, as I said if I do -w - I see plenty of data scrolling up the screen.

The network card is a VMware vmxnet adapter on a VM so I was wondering if the vswitch was blocking promiscuous mode but even -p gives the same problem so I may be confusing the issue.

Last edited by greyarea; 10-18-2010 at 04:36 PM. Reason: typo
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Writing binary data under python. dracuss Programming 12 04-14-2009 08:57 AM
Incorrect source/destination ports when reading tcpdump data with libpcap Nylex Programming 2 06-21-2007 04:10 AM
3Com fiber n/w card - only start to recieves data when tcpdump runs sceadu Linux - Networking 1 07-27-2005 08:00 AM
tethereal and tcpdump: -y invalid data link type 1 murugesan Linux - Wireless Networking 0 05-30-2004 11:28 PM
CD RW -- Writing Data to CD dnachtwey Linux - Hardware 39 01-25-2004 06:22 PM


All times are GMT -5. The time now is 10:17 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration