Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi guys,
I'm currently dealing with the dilemma of whether if is worthwhile to pipe the output of "tcpdump" command into a simple perl script, which will indeed do a select-query from myslq. Afterwards ( as a result from the previous logic) there's gonna be an insertion into a table (in the same mysql).
Have anybody tried/heard this as an effective approach? I need some advice because I haven't found much evidence on this topic.
As acid_kewpie implied, it'd help if you explained a bit more about what you want to do and why.
For example, is this going to be an ongoing stream of tcpdump, or could you just dump to a file, then read that; you have to consider if the Perl prog will be able keep up with the incoming data flow.
Chris,
As you've mentioned, streaming the output of tcpdump into a file plus using a Perl script, proved to be a suitable solution, which solved my requirement. But going back to the initial approach, it might be great if tcpdump had some way to store its output in a database just for logging purposes. But thinking a little bit in the aim of tcpdump itself, maybe it wasn't build with this usage in mind, because there are other better ways to do this (e.g. perl script).
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.