Thanks for the reply. Something I failed to mention before; swapped out the default servicenotify and hostnotify scripts for a bash script. I am sending these notifications through amazon's SNS service. This is the servicenotify file I created:
Code:
sns-publish arn:aws:sns:us-west-1:xxxxxxxxxxxx:NAGIOS --message "There is a $1 with service $2 on $3 at $4. State is: $5. ADDITIONALINFO: $6 $7 $8 $9 $10 $11 $12 $13 $14 $15 $16 $17 $18 $19 $20 $21 $22 $23" |tee -a /tmp/nagios.log
Adding this to the end did not result in a file:
Code:
echo "$1 $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 $12 $13 $14 $15" >> /tmp/test
also resulted in no output for [CRITICAL]] but worked for the [OK]
I think there is a problem receiving the log file as passed parameters in this bash script.
This is the output of check_logfiles for an example exception:
Code:
CRITICAL - (2 errors in check_logfiles.protocol-2012-07-12-03-53-56) - Message : System.Exception: Registration of new users is disabled. RelatedId
xxxxxxxx-xxxx-xxxx-xxxxxxxxxxxx ...|TestException2_lines=118 TestException2_warnings=0 TestException2_criticals=2 TestException2_unknowns=0
tag TestException2 CRITICAL
Message : testexceptionRegistration of new users is disabled.
Message : System.Exception: Registration of new users is disabled. RelatedId xxxxxxxx-xxxx-xxxx-xxxxxxxxxxxx
Is there a way around this?