On Fri, 24 Feb 2006, John Purser wrote:

> I'm writing a system admin script in python that checks recently
> accessed files for keywords like "failed, denied, error,..." etc.  I'm
> using popen to call grep -F <LIST> <LOG_FILE> but it's VERY slow.  Can
> anyone suggest a faster method to do this?

Hi John,

This should not be slow, but we have to see what exactly is going on here.
Can you give us more details?  How many keywords are you typically passing
in <LIST>?  How large is the <LOG_FILE>?  What do you mean by "slow"?

_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to