[Tutor] Grepping a file for words in a list

John Purser jmpurser at gmail.com
Fri Feb 24 20:18:06 CET 2006


Hello,

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?

Thanks,

John Purser
Ubuntu Linux
Python 2.4

-- 
Courage is your greatest present need.


More information about the Tutor mailing list