--=-Z4cEQIgXkTQ/NhMzbNw6
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
I noticed that the macro $DATETIME$ is dead and should now be
$LONGDATETIME$.
Here's the patch to fix the docs and sample configs.
--=-Z4cEQIgXkTQ/NhMzbNw6
Content-Disposition: attachment; filename=little_macro.patch
Content-Type: text/x-patch; name=little_macro.patch; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Index: sample-config/template-object/minimal.cfg.in
===================================================================
RCS file: /cvsroot/nagios/nagios/sample-config/template-object/minimal.cfg.in,v
retrieving revision 1.2
diff -u -r1.2 minimal.cfg.in
--- sample-config/template-object/minimal.cfg.in 4 Oct 2002 00:12:48 -0000 1.2
+++ sample-config/template-object/minimal.cfg.in 12 Nov 2004 15:34:04 -0000
@@ -58,7 +58,7 @@
define command{
command_name notify-by-email
- command_line /usr/bin/printf "%b" "***** Nagios @VERSION@ *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: $DATETIME$\n\nAdditional Info:\n\n$OUTPUT$" | @MAIL_PROG@ -s "** $NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$
+ command_line /usr/bin/printf "%b" "***** Nagios @VERSION@ *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: $LONGDATETIME$\n\nAdditional Info:\n\n$OUTPUT$" | @MAIL_PROG@ -s "** $NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$
}
@@ -67,7 +67,7 @@
define command{
command_name host-notify-by-email
- command_line /usr/bin/printf "%b" "***** Nagios @VERSION@ *****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress: $HOSTADDRESS$\nInfo: $OUTPUT$\n\nDate/Time: $DATETIME$\n" | @MAIL_PROG@ -s "Host $HOSTSTATE$ alert for $HOSTNAME$!" $CONTACTEMAIL$
+ command_line /usr/bin/printf "%b" "***** Nagios @VERSION@ *****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress: $HOSTADDRESS$\nInfo: $OUTPUT$\n\nDate/Time: $LONGDATETIME$\n" | @MAIL_PROG@ -s "Host $HOSTSTATE$ alert for $HOSTNAME$!" $CONTACTEMAIL$
}
Index: sample-config/template-object/misccommands.cfg.in
===================================================================
RCS file: /cvsroot/nagios/nagios/sample-config/template-object/misccommands.cfg.in,v
retrieving revision 1.5
diff -u -r1.5 misccommands.cfg.in
--- sample-config/template-object/misccommands.cfg.in 19 Feb 2003 02:01:11 -0000 1.5
+++ sample-config/template-object/misccommands.cfg.in 12 Nov 2004 15:34:04 -0000
@@ -49,28 +49,28 @@
# 'notify-by-email' command definition
define command{
command_name notify-by-email
- command_line /usr/bin/printf "%b" "***** Nagios @VERSION@ *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: $DATETIME$\n\nAdditional Info:\n\n$SERVICEOUTPUT$" | @MAIL_PROG@ -s "** $NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$
+ command_line /usr/bin/printf "%b" "***** Nagios @VERSION@ *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: $LONGDATETIME$\n\nAdditional Info:\n\n$SERVICEOUTPUT$" | @MAIL_PROG@ -s "** $NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$
}
# 'notify-by-epager' command definition
define command{
command_name notify-by-epager
- command_line /usr/bin/printf "%b" "Service: $SERVICEDESC$\nHost: $HOSTNAME$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\nInfo: $SERVICEOUTPUT$\nDate: $DATETIME$" | @MAIL_PROG@ -s "$NOTIFICATIONTYPE$: $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$" $CONTACTPAGER$
+ command_line /usr/bin/printf "%b" "Service: $SERVICEDESC$\nHost: $HOSTNAME$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\nInfo: $SERVICEOUTPUT$\nDate: $LONGDATETIME$" | @MAI
...[email truncated]...
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]