Search the web
Sign In
New User? Sign Up
exim-users · Exim MTA
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Message search is now enhanced, find messages faster. Take it for a spin.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
[Exim] Shell trick help   Message List  
Reply | Forward Message #69816 of 85778 |
OK - I'm running tail on exim logs and extracting IP addresses that
match a specific criteria. So I have a stream of raw IP addresses coming
in that I want to pipe into a program that takes each IP address and
runs a command with the IP address as the parameter.

How do I do that?


--

## List details at http://www.exim.org/mailman/listinfo/exim-users Exim details
at http://www.exim.org/ ##




Tue Jul 27, 2004 8:15 pm

marc@...
Send Email Send Email

Forward
Message #69816 of 85778 |
Expand Messages Author Sort by Date

OK - I'm running tail on exim logs and extracting IP addresses that match a specific criteria. So I have a stream of raw IP addresses coming in that I want to...
Marc Perkel
marc@...
Send Email
Jul 27, 2004
8:21 pm

... I believe if you pipe the output (stream of IPs) to: xargs -n 1 COMMAND where COMMAND is your command that takes one IP as a parameter; you'll get what you...
Michael F. Sprague
mfs@...
Send Email
Jul 27, 2004
8:26 pm

... If you mean what I think you mean then the shellscript answer would be something like: mangle_ip() { while read ip do my_command "$ip" done } tail -f...
Julian King
jpk28@...
Send Email
Jul 27, 2004
8:28 pm

... What I often do is something like tail -f mainlog | sed '/.* H=[^[]*[[]\([^]]*\).*/!d;s//ping -c 1 \1/' | sh Tony. -- f.a.n.finch <dot@...>...
Tony Finch
dot@...
Send Email
Jul 28, 2004
9:07 am
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help