PERL based log analyzer
SourceForge.net Logo
Home Home Contact us Contacts
Overview Documentation Downloads Contacts Links
 
News & Updates
 
July 21, 2008
v 1.0 now available
Quick Links
 
Sourceforge project's page
CeCILL license
CEA web site
A simple usage of variable next up previous contents
Next: A little more complicated: Up: A boolean composite event Previous: Re-spawning a dead process   Contents

A simple usage of variable

I want to look either for Titi and Toto, but want just an action. So, I'll make use of internal variable $(LAST_PATTERN) to define only one action:
Kazimir: LogFile = /dev/tty ; EventDir = /tmp/eventdir ; OutputDir = /tmp/outputdir ;\
	LockFile = /tmp/kazimir.lock ; EventUpdateInt = 5 

Log: Name = syslog ; Type = ASCII ; Path = /var/adm/messages ; TimeFormat=%b %e %H:%M:%S;


Pattern:  Name =Toto; RegExp =toto was here; Log = syslog ; 
Pattern:  Name =Titi; RegExp =titi was here; Log = syslog ;

Event : Name =TotoTitiEvent; Window = 30s; 
Begin 
        Toto || Titi  
End

Order: Name = ordre1 ; Event =TotoTitiEvent; Action = Action1 ;
Action: Name = Action1 ; Path = echo "$(LAST_PATTERN) was found" ;



Philippe Deniel 2008-07-22
Designed by CMG Technologies, adapted by Thomas LEIBOVICI
Design downloaded from Free Templates