Posts: 74
Number of Nagios server: 2
Nagios Versions: 3.2.0
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: > 500
Number of services: > 20
OS: Solaris
Plugin Versions: ?
NDO Version: 2
![]() |
Quellcode |
1 2 3 4 5 6 7 8 9 10 11 |
define command { command_name service-notify command_line $USER1$/notify \ --state '$SERVICESTATE$' \ --service '$SERVICEDESC$' \ --ntype '$NOTIFICATIONTYPE$' \ --hostname '$HOSTADDRESS$' \ --output '$SERVICEOUTPUT$' \ --longoutput '$LONGSERVICEOUTPUT$' \ --notesurl '$SERVICENOTESURL$' } |
Posts: 5,329
Gender: male
Number of Nagios server: 2
Nagios Versions: 3.2.1
Icinga-Version(en): Icinga 1.0.1
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: >70
Number of services: >200
OS: SLES10
Plugin Versions: 1.4.11
Other Addons: NRPE 2.6, NSCA 2.7, PNP 0.4.14 / 0.6
Posts: 74
Number of Nagios server: 2
Nagios Versions: 3.2.0
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: > 500
Number of services: > 20
OS: Solaris
Plugin Versions: ?
NDO Version: 2
3
Friday, May 20th 2011, 9:18am
Zitat von »Wolfgang«
Feature
This post has been edited 1 times, last edit by "Steph" (May 20th 2011, 9:56am)
Posts: 2,102
Birthday: May 30th 1983 (27)
Gender: male
Location: Wien
Occupation: DNS & Monitoring Developer
Number of Nagios server: 3x Icinga prod, 2x test/dev
Nagios Versions: s/nagios/icinga/
Icinga-Version(en): 1.4.0 / GIT
Distributed monitoring: Ja
Redundant monitoring: Ja
Number of hosts: 1000+
Number of services: 15000+
OS: RHEL 5.6 x64
Plugin Versions: 1.4.15
IDO-Version: 1.4.0 / GIT MySQL/Postgresql/Oracle
Other Addons: PNP 0.6.11, check_mk GIT
4
Friday, May 20th 2011, 10:04am
Zitat von »Steph«
Nachtrag: Trifft es DOCH, denn ich habe probeweise das '&' entfernt und schon erscheint es :-(
Zitat von »Steph«
Mist! Meiner Meinung nach aber ein bug. Zumindest in der Doku, oder?
Posts: 74
Number of Nagios server: 2
Nagios Versions: 3.2.0
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: > 500
Number of services: > 20
OS: Solaris
Plugin Versions: ?
NDO Version: 2
5
Friday, May 20th 2011, 10:30am
Zitat von »dnsmichi«
wo hast du das entfernt? im macro output oder in der nagios.cfg?
Zitat von »dnsmichi«
wieso? steht doch eh genau da, dass '&' entfernt wird in macros, was bei dir ja auch der fall ist. wenn du das nicht haben moechtest, musst du die config anpassen.
Zitat
This option allows you to specify illegal characters that should be stripped from macros before being used in notifications, event handlers, and other commands. This DOES NOT affect macros used in service or host check commands. You can choose to not strip out the characters shown in the example above, but I recommend you do not do this. Some of these characters are interpreted by the shell (i.e. the backtick) and can lead to security problems. The following macros are stripped of the characters you specify:
$HOSTOUTPUT$, $HOSTPERFDATA$, $HOSTACKAUTHOR$, $HOSTACKCOMMENT$, $SERVICEOUTPUT$, $SERVICEPERFDATA$, $SERVICEACKAUTHOR$, and $SERVICEACKCOMMENT$
Posts: 1,406
Number of Nagios server: 2-5
Nagios Versions: 1-3
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: 80-200
Number of services: 1400-2000
OS: Linux
Plugin Versions: Whatever I can download, patch, or cobble together myself :-)
Other Addons: n2rrd, PNP, livestatus
6
Friday, May 20th 2011, 2:15pm
Ist es und es ist IMHO auch den relevanten Leuten bekannt, daß die Macro Sanitization ziemlich wild 'rumagiert, wo sie offiziell nicht hingehört.
Zitat von »Steph«
Trifft es leider nicht. Das verlinkte bezieht sich nicht auf SERVICENOTESURL und nur um die geht es mir.
Nachtrag: Trifft es DOCH, denn ich habe probeweise das '&' entfernt und schon erscheint es :-(
Mist! Meiner Meinung nach aber ein bug. Zumindest in der Doku, oder?
Posts: 2,102
Birthday: May 30th 1983 (27)
Gender: male
Location: Wien
Occupation: DNS & Monitoring Developer
Number of Nagios server: 3x Icinga prod, 2x test/dev
Nagios Versions: s/nagios/icinga/
Icinga-Version(en): 1.4.0 / GIT
Distributed monitoring: Ja
Redundant monitoring: Ja
Number of hosts: 1000+
Number of services: 15000+
OS: RHEL 5.6 x64
Plugin Versions: 1.4.15
IDO-Version: 1.4.0 / GIT MySQL/Postgresql/Oracle
Other Addons: PNP 0.6.11, check_mk GIT
7
Friday, May 20th 2011, 5:10pm
![]() |
Quellcode |
1 2 3 4 5 |
/* host/service output/perfdata and author/comment macros should get cleaned */ if((x>=16 && x<=19) ||(x>=49 && x<=52) || (x>=99 && x<=100) || (x>=124 && x<=127)){ *clean_options|=(STRIP_ILLEGAL_MACRO_CHARS|ESCAPE_MACRO_CHARS); log_debug_info(DEBUGL_MACROS,2," New clean options: %d\n",*clean_options); } |
![]() |
Quellcode |
1 |
#define MACRO_SERVICENOTESURL 78 |