Error when starting nagios

Sameka Prather Sameka.Prather at noaa.gov
Fri Apr 7 16:44:03 CEST 2006


Hello Again Jeff,

I do apologize for the delay in my response.
I ran the the nagios script with -x and this was the output.  I still
unclear to me why I get the error.   Any ideas would be greatly
appreciated. See below
[root at case1 init.d]# service nagios start
+ '[' -f /etc/rc.d/init.d/functions ']'
+ . /etc/rc.d/init.d/functions
++ TEXTDOMAIN=initscripts
++ umask 022
++ PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/X11R6/bin
++ export PATH
++ '[' -z '' ']'
++ COLUMNS=80
++ '[' -z '' ']'
+++ /sbin/consoletype
++ CONSOLETYPE=pty
++ '[' -f /etc/sysconfig/i18n -a -z '' ']'
++ . /etc/sysconfig/i18n
+++ LANG=en_US.UTF-8
+++ SUPPORTED=en_US.UTF-8:en_US:en
+++ SYSFONT=latarcyrheb-sun16
++ '[' pty '!=' pty ']'
++ export LANG
++ '[' -z '' ']'
++ '[' -f /etc/sysconfig/init ']'
++ . /etc/sysconfig/init
+++ BOOTUP=color
+++ GRAPHICAL=yes
+++ RES_COL=60
+++ MOVE_TO_COL=echo -en \033[60G
+++ SETCOLOR_SUCCESS=echo -en \033[0;32m
+++ SETCOLOR_FAILURE=echo -en \033[0;31m
+++ SETCOLOR_WARNING=echo -en \033[0;33m
+++ SETCOLOR_NORMAL=echo -en \033[0;39m
+++ LOGLEVEL=3
+++ PROMPT=yes
++ '[' pty = serial ']'
++ '[' color '!=' verbose ']'
++ INITLOG_ARGS=-q
+ prefix=/usr/local/nagios
+ exec_prefix=/usr/local/nagios
+ NagiosBin=/usr/local/nagios/bin/nagios
+ NagiosCfg=/usr/local/nagios/etc/nagios.cfg
+ NagiosLog=/usr/local/nagios/var/status.log
+ NagiosTmp=/usr/local/nagios/var/nagios.tmp
+ NagiosSav=/usr/local/nagios/var/status.sav
+ NagiosCmd=/usr/local/nagios/var/rw/nagios.cmd
+ NagiosVar=/usr/local/nagios/var
+ NagiosRun=/usr/local/nagios/var/nagios.lock
+ NagiosLckDir=/var/lock/subsys
+ NagiosLckFile=nagios
+ NagiosCGI=/usr/local/nagios/sbin
+ Nagios=apache
+ test -f /usr/local/nagios/bin/nagios
+ test -f /usr/local/nagios/etc/nagios.cfg
+ echo 'Starting network monitor: nagios'
Starting network monitor: nagios
+ su -l apache -c 'touch /usr/local/nagios/var/nagios.log
/usr/local/nagios/var/status.sav'
*This account is currently not available. *
+ rm -f /usr/local/nagios/var/rw/nagios.cmd
+ /usr/local/nagios/bin/nagios -d /usr/local/nagios/etc/nagios.cfg
+ '[' -d /var/lock/subsys ']'
+ touch /var/lock/subsys/nagios
+ sleep 1
+ status_nagios nagios
+ test '!' -f /usr/local/nagios/var/nagios.lock
++ head -n 1 /usr/local/nagios/var/nagios.lock
+ NagiosPID=18594
+ test -x /usr/local/nagios/sbin/daemonchk.cgi
+ ps -p 18594
 PID TTY          TIME CMD
18594 ?        00:00:00 nagios
+ return 0


Thank you,
Sameka Prather
Office of Internet Services
sameka.prather at noaa.gov
301-713-1384 x 109





jeff vier wrote:
> On Fri, 2006-03-31 at 07:34 -0500, Sameka Prather wrote:
>  
>> I am not sure what you mean.  Do you want me to add -s to the first
>> line in the script #! -x?  So that line would look like #! /bin/sh -x.
>>    
>
> without the space after the #!, yes.
>
> #!/bin/sh -x
>
> a quick google search found:
> http://www.injunea.demon.co.uk/pages/page213.htm
>  
Thank you,
Sameka Prather
Office of Internet Services
sameka.prather at noaa.gov
301-713-1384 x 109





Sameka Prather wrote:
> Hello Again Jeff,
>
> I do apologize for the delay in my response.
> I ran the the nagios script with -x and this was the output.  I still
unclear to me why I get the error.   Any ideas would be greatly
appreciated. See below
> [root at case1 init.d]# service nagios start
> + '[' -f /etc/rc.d/init.d/functions ']'
> + . /etc/rc.d/init.d/functions
> ++ TEXTDOMAIN=initscripts
> ++ umask 022
> ++ PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/X11R6/bin
> ++ export PATH
> ++ '[' -z '' ']'
> ++ COLUMNS=80
> ++ '[' -z '' ']'
> +++ /sbin/consoletype
> ++ CONSOLETYPE=pty
> ++ '[' -f /etc/sysconfig/i18n -a -z '' ']'
> ++ . /etc/sysconfig/i18n
> +++ LANG=en_US.UTF-8
> +++ SUPPORTED=en_US.UTF-8:en_US:en
> +++ SYSFONT=latarcyrheb-sun16
> ++ '[' pty '!=' pty ']'
> ++ export LANG
> ++ '[' -z '' ']'
> ++ '[' -f /etc/sysconfig/init ']'
> ++ . /etc/sysconfig/init
> +++ BOOTUP=color
> +++ GRAPHICAL=yes
> +++ RES_COL=60
> +++ MOVE_TO_COL=echo -en \033[60G
> +++ SETCOLOR_SUCCESS=echo -en \033[0;32m
> +++ SETCOLOR_FAILURE=echo -en \033[0;31m
> +++ SETCOLOR_WARNING=echo -en \033[0;33m
> +++ SETCOLOR_NORMAL=echo -en \033[0;39m
> +++ LOGLEVEL=3
> +++ PROMPT=yes
> ++ '[' pty = serial ']'
> ++ '[' color '!=' verbose ']'
> ++ INITLOG_ARGS=-q
> + prefix=/usr/local/nagios
> + exec_prefix=/usr/local/nagios
> + NagiosBin=/usr/local/nagios/bin/nagios
> + NagiosCfg=/usr/local/nagios/etc/nagios.cfg
> + NagiosLog=/usr/local/nagios/var/status.log
> + NagiosTmp=/usr/local/nagios/var/nagios.tmp
> + NagiosSav=/usr/local/nagios/var/status.sav
> + NagiosCmd=/usr/local/nagios/var/rw/nagios.cmd
> + NagiosVar=/usr/local/nagios/var
> + NagiosRun=/usr/local/nagios/var/nagios.lock
> + NagiosLckDir=/var/lock/subsys
> + NagiosLckFile=nagios
> + NagiosCGI=/usr/local/nagios/sbin
> + Nagios=apache
> + test -f /usr/local/nagios/bin/nagios
> + test -f /usr/local/nagios/etc/nagios.cfg
> + echo 'Starting network monitor: nagios'
> Starting network monitor: nagios
> + su -l apache -c 'touch /usr/local/nagios/var/nagios.log
/usr/local/nagios/var/status.sav'
> *This account is currently not available. *
> + rm -f /usr/local/nagios/var/rw/nagios.cmd
> + /usr/local/nagios/bin/nagios -d /usr/local/nagios/etc/nagios.cfg
> + '[' -d /var/lock/subsys ']'
> + touch /var/lock/subsys/nagios
> + sleep 1
> + status_nagios nagios
> + test '!' -f /usr/local/nagios/var/nagios.lock
> ++ head -n 1 /usr/local/nagios/var/nagios.lock
> + NagiosPID=18594
> + test -x /usr/local/nagios/sbin/daemonchk.cgi
> + ps -p 18594
>  PID TTY          TIME CMD
> 18594 ?        00:00:00 nagios
> + return 0
>
>
> Thank you,
> Sameka Prather
> Office of Internet Services
> sameka.prather at noaa.gov
> 301-713-1384 x 109
>
>
>
>
>
> jeff vier wrote:
>> On Fri, 2006-03-31 at 07:34 -0500, Sameka Prather wrote:
>>  
>>> I am not sure what you mean.  Do you want me to add -s to the first
>>> line in the script #! -x?  So that line would look like #! /bin/sh -x.
>>>    
>>
>> without the space after the #!, yes.
>>
>> #!/bin/sh -x
>>
>> a quick google search found:
>> http://www.injunea.demon.co.uk/pages/page213.htm
>>  

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20060407/1e1b3ee9/attachment.html>


More information about the Users mailing list