Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 03-27-2009, 01:16 AM   #1
LQ Newbie
Registered: Feb 2009
Posts: 15
Blog Entries: 1

Rep: Reputation: 0
SWATCH::not able to get the correct match count when i use regular expression

This post regarding Swatch alerts... Currently i have a requirement which should count the number of "Matched string" occured in a perticular time frame and send me a mail with the count when the given time frame gets over... Below is my file which my configuration looks for

watchfor /CRON END Job:.*CRON_EXEC_STATUS_FAILED|ORA-\d{5}|ERROR:CORE.*java.lang.OutOfMemoryError/
mail addresses=vijay\, subject=[ALERTS\ Failure list ]\ ERRORS\ in\ vijay.log,mailer=/usr/sbin/sendmail -oi -t 
throttle 00:20:00,key=$1

It works perfectly fine except for "ORA-\d{5}" alerts...The problem i am facing here is, It is not giving me a proper match count.. if this error has occured once or twice, i get a mail stating it has occured 10 times, 12 times and more... I am not sure how to fix it...
Can any one help me...


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Regular expression to match "^" then a number? PsychosisNode Linux - Newbie 1 01-14-2007 09:26 AM
Regular expression to match 4 or more alpha characters sixerjman Programming 15 11-27-2006 12:03 AM
Don't match a regular expression dakensta Programming 7 09-21-2006 03:48 AM
perl regular expression a char match richikiki Programming 8 07-19-2006 03:37 AM
Regular expression to match a valid URL string vharishankar Programming 13 07-21-2005 09:17 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:22 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration