> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:python-
> [EMAIL PROTECTED] On Behalf Of m
> Sent: Wednesday, August 06, 2008 1:25 PM
> To: python-list@python.org
> Subject: Monitor and compare two log files in real time
> 
> I have a script I would like to write but I am not sure of where to
> start / approach. Perhaps someone could help direct me in the right
> direction. Any advice is appreciated.
> 
> I would like to write a python script that monitors two log files.
> If a certain string, lets say string1 shows up in logfile-A, I want to
> check if that same string shows up in log file-B within 8 minutes. If
> it does not show up within 8 minutes, send an email ( using sendmail
> or postfix).
> 
> Do you have any suggestions?
> --

Google on "python tail" to get a python implementation of the unix tail
command.  The rest should be easy. 

http://code.activestate.com/recipes/157035/



*****

The information transmitted is intended only for the person or entity to which 
it is addressed and may contain confidential, proprietary, and/or privileged 
material. Any review, retransmission, dissemination or other use of, or taking 
of any action in reliance upon this information by persons or entities other 
than the intended recipient is prohibited. If you received this in error, 
please contact the sender and delete the material from all computers. GA622


--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to