LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (http://www.linuxquestions.org/questions/linux-server-73/)
-   -   tshark output to file (http://www.linuxquestions.org/questions/linux-server-73/tshark-output-to-file-713951/)

noir911 03-23-2009 11:25 PM

tshark output to file
 
I'm trying to get tshark output to file but it's not working

Tried:

Quote:

tshark -i eth0 -n port 68 -R 'bootp.type == 2' -o
column.format:'"Source MAC","%hs"' > /tmp/capture &
but get nothing in the file. ps -ef | grep shark shows tshark -i eth0
-n port 68 -R bootp.type == 2 -o column.format:"Source MAC","%hs"

pkill tshark - and I get the /tmp/capture file with all the entries!

Also tried

tshark -i eth0 -n port 68 -R 'bootp.type == 2' -o
column.format:'"Source MAC","%hs"' | tee /tmp/file

nothing in the file and when I do ctrl-c, I get entries in the file.

chrism01 03-25-2009 06:17 AM

Sounds like you're Suffering from Buffering http://perl.plover.com/FAQs/Buffering.html (its not just a Perl thing btw)


All times are GMT -5. The time now is 07:22 AM.