![]() | Register | FAQ | Members | Social Groups | User Map | Calendar | Search | Today's Posts | Mark Forums Read |
*nix
*nix forum sponsored by |
| ||
| | | LinkBack | Thread Tools | Search Thread |
| Sponsored Links |
| | #1 |
![]() Join Date: Oct 2007
Posts: 186
Thanks: 25
Thanked 7 Times in 7 Posts
Rep Power: 7 | Checking my config file and i'm getting the following two errors... Code: Error: Service notification command 'notify-by-email' specified for contact 'nagios' is not defined anywhere! Error: Host notification command 'host-notify-by-email' specified for contact 'nagios' is not defined anywhere! where do i specify these options as i can't see anything in the documentation..... Dan |
| |
| | #2 | |
![]() Join Date: Jul 2006 Location: Nottingham
Posts: 881
Thanks: 63
Thanked 162 Times in 112 Posts
Rep Power: 40 | Quote:
nano /usr/local/nagios/etc/objects/contacts.cfg | |
| |
| | #3 |
![]() Join Date: Jun 2005 Location: Fylde, Lancs, UK.
Posts: 10,753
Thanks: 93
Thanked 381 Times in 327 Posts
Blog Entries: 1 Rep Power: 98 | I have the following in my commands.cfg Code: # 'host-notify-by-email' command definition
define command{
command_name host-notify-by-email
command_line /usr/bin/printf "%b" "***** Nagios 2.6 *****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress: $HOSTADDRESS$\nInfo: $HOSTOUTPUT$\n\nDate/Time: $LONGDATETIME$\n" | /usr/bin/mail -s "Host $HOSTSTATE$ alert for $HOSTNAME$!" $CONTACTEMAIL$
}
# 'notify-by-email' command definition
define command{
command_name notify-by-email
command_line /usr/bin/printf "%b" "***** Nagios 2.6 *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: $LONGDATETIME$\n\nAdditional Info:\n\n$SERVICEOUTPUT$" | /usr/bin/mail -s "* *$NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$
}
|
| |
| | #4 | ||
![]() Join Date: Oct 2007
Posts: 186
Thanks: 25
Thanked 7 Times in 7 Posts
Rep Power: 7 | Quote:
Quote:
Geoff - yours command.cfg seems to give me errors ... Code: Nagios 3.0.1
Copyright (c) 1999-2008 Ethan Galstad (http://www.nagios.org)
Last Modified: 04-01-2008
License: GPL
Reading configuration data...
Error: Invalid command object directive 'Address:'.
Error: Could not add object property in file '/usr/local/nagios/etc/objects/commands.cfg' on line 38.
***> One or more problems was encountered while processing the config files...
Check your configuration file(s) to ensure that they contain valid
directives and data defintions. If you are upgrading from a previous
version of Nagios, you should be aware that some variables/definitions
may have been removed or modified in this version. Make sure to read
the HTML documentation regarding the config files, as well as the
'Whats New' section to find out what has changed.
| ||
| |
| | #5 |
![]() | What is on line 38 of that file? |
| |
| | #7 |
![]() Join Date: Oct 2007
Posts: 186
Thanks: 25
Thanked 7 Times in 7 Posts
Rep Power: 7 | Think i've solved the problem .... was a classic case of PEBKAC .... |
| |
| | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Installing Nagios... what do you want to know? | Ric_ | *nix | 51 | 10-11-2009 06:23 AM |
| Nagios Problems | DanW | *nix | 5 | 07-05-2008 01:56 PM |
| nagios error | dezt | *nix | 13 | 13-03-2008 03:02 PM |
| Nagios - MRTG | rush_tech | *nix | 2 | 05-03-2008 04:54 PM |
| Nagios Problem | sqdge | *nix | 10 | 25-04-2007 09:11 PM |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search Thread |
| |










