Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re^3: capture output of tcpdump and PID

by aaron_baugher (Deacon)
on May 24, 2012 at 18:29 UTC ( #972289=note: print w/ replies, xml ) Need Help??


in reply to Re^2: capture output of tcpdump and PID
in thread capture output of tcpdump and PID

How do you set/change the channel? If you do it by giving tcpdump an argument, then I suspect you're out of luck. You'll just have to stop the process and restart it with the new channel setting. If the channel can be changed with some other utility while tcpdump is running, then it should be fairly simple: read from the pipe until you want to change it (maybe based on how much time has elapsed since you started), and then run the other utility, then continue reading from the pipe. There may be some buffered output from tcpdump already waiting at the moment you change the channel. If that's a problem, you may have to do something more fancy.

Aaron B.
Available for small or large Perl jobs; see my home node.


Comment on Re^3: capture output of tcpdump and PID
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://972289]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (14)
As of 2014-10-23 14:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (125 votes), past polls