Antwort: UTF8 Japanese characters in macros

rob.moss at uk.bnpparibas.com rob.moss at uk.bnpparibas.com
Wed Oct 18 10:34:02 CEST 2006


nagios-users-bounces at lists.sourceforge.net wrote on 18/10/2006 09:12:05:
> nagios-users-bounces at lists.sourceforge.net schrieb am 18.10.2006 
04:26:19:
> 
> > /usr/bin/printf "%b" "***** Nagios  *****\n\nNotification Type:
> > $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress:
> > $HOSTADDRESS$\n$HOSTNOTES$\n\nInfo: $HOSTOUTPUT$\n\nDate/Time:
> > $LONGDATETIME$\n" | /usr/bin/mail -s "Host $HOSTSTATE$ alert for
> > $HOSTNAME$!" $CONTACTEMAIL$
> [SNIP]
> > Both printf and mail work fine with UTF8 japanese, and tests using 
only
> > the $HOSTNOTES$ macro yeilds similar results (nothing output).
> > The CGI's work fine, and display the japanese, so it seems the macro
> > processing is not able to handle the characters.
> > 
> > Has anyone had similar problems, and is there a solution?
> 
> I can't try the japanese UTF, but are you sure that /usr/bin/printf
> supports UTF8? Typing printf at the shell is not the same as using
> /usr/bin/printf. The bash built-in printf function is very different
> from the external executable and has caused lots of headaches to me
> already. It might be the source of your problem too.
> 
> Sascha
> 
> PS: This problem is one of the reasons I strongly discourage the current
> standard of how default notifications are generated...

I am also totally against how the default mail action works, which is why 
I wrote a perl script to do the emailing a little more elegantly

http://www.nagiosexchange.org/Utilities.16.0.html?&tx_netnagext_pi1[p_view]=698

Cheers
rob/mossko


This message and any attachments (the "message") is 
intended solely for the addressees and is confidential. 
If you receive this message in error, please delete it and
immediately notify the sender. Any use not in accord with
its purpose, any dissemination or disclosure, either whole
or partial, is prohibited except formal approval. The internet
can not guarantee the integrity of this message.
BNP PARIBAS (and its subsidiaries) shall (will) not
therefore be liable for the message if modified. 

**********************************************************************************************

BNP Paribas Private Bank London Branch is authorised
by CECEI & AMF and is regulated by the Financial Services
Authority for the conduct of its investment business in
the United Kingdom.

BNP Paribas Securities Services London Branch is authorised 
by CECEI & AMF and is regulated by the Financial Services 
Authority for the conduct of its investment business in 
the United Kingdom.
  
BNP Paribas Fund Services UK Limited is authorised and 
regulated by the Financial Services Authority

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20061018/ed084a2c/attachment.html>
-------------- next part --------------
-------------------------------------------------------------------------
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
-------------- next part --------------
_______________________________________________
Nagios-users mailing list
Nagios-users at 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


More information about the Users mailing list