[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

OT: tail -f | while read



hi,
why does the following not work:

  tail -f /var/log/syslog | grep something | while read i; do myprog $i; done

i basically need to run myprog as soon as a new entry in syslog
happens that matches the criteria of the grep call. it needs to happen
immediately.

thanks,
martin;              (greetings from the heart of the sun.)
  \____ echo mailto: !#^."<*>"|tr "<*> mailto:"; net@madduck
-- 
"the human brain is like an enormous fish --
 it is flat and slimy
 and has gills through which it can see."
                                                       -- monty python



Reply to: