On Wed, 22 Apr 2009 12:38:47 -0700, Evuraan::ഏവൂരാന്‍  <[email protected]> 
wrote:
> but this below, does not work
> 
>  tail -f /var/log/apache2/access.log |awk ' /192.168.1.100/ {  print
> $0 | "mail [email protected]  "}'

I would suggest to keep the system() approach:

        tail -f /var/log/apache2/access.log | awk '/192.168.1.100/ { 
system(sprintf("echo %s | mail [email protected]", $0)); }'



> Any pointers would be much appreciated.

It should work, but I'm sure someonle else will soon show you
some more elegant way. :-)



-- 
Polytropon
>From Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[email protected]"

Reply via email to