Reputation: 345
When I kill a tcpdump process, I get the following three lines:
NN packets captured
NN packets received by filter
NN packets dropped by kernel
I am piping the output of tcpdump into a txt file and want to keep my terminal clean. Is there a way to suppress this information?
Upvotes: 2
Views: 711
Reputation: 3638
From this question here, the tcpdump
stats and header lines are a part of stderr
. So, if you want to suppress this information and store the packet information in a file, you can do:
tcpdump 2> /dev/null > output.txt
Using /dev/null/
will discard the stderr
output.
Upvotes: 2