Hugo van der Kooij wrote:
On Fri, 11 Aug 2006, Hari Sekhon wrote:Hari Sekhon wrote:Here is an exampleCRITICAL: Only 19.11G (4%) free on 92.168.1.138ig2 Why does it seem to be mangled? Is this a character set issue or a local issue or something?also, the web interface shows this normally: CRITICAL: Only 18.85G (4%) free on \\192.168.1.138\big2 but the email alerts always come out as CRITICAL: Only 18.88G (4%) free on 92.168.1.138ig2Which makes sense if you read the printf() documentation. You are using a character which has a special meaning in string handling environments. Just get rid of those backslashes or escape them properly.It's not that terrible cos I still know what's going on but this shouldn't happen, and I'd like to resolve it.You got exactly what you ordered. Hugo. After following your suggestion regarding prinf and checking the previously unchanged misccommand.cfg I'm not entirely sure what is going on here. The definition for email is below: # 'notify-by-email' command definition define command{ command_name notify-by-email command_line /usr/bin/printf "%b" "***** Nagios *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: $DATETIME$\n\nAdditional Info:\n\n$OUTPUT$" | /bin/mail -s "** $NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$ } This doesn't look bad to me, it seems to simply be using lots of Macro$ so I assume that the macro must be sending it something funny.... Will have to scratch my head and try to track that down. Hari |
------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________ Nagios-users mailing list Nagios-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/nagios-users ::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. ::: Messages without supporting info will risk being sent to /dev/null