external commands

Jonathan Nichols jnichols at pbp.net
Wed Aug 14 02:12:38 CEST 2002


It's not creating the correct file, I guess... I removed the directory and
basically copy/pasted directly from the section on external commands in the
documentation. (That's what's in the perms.sh file)
Yours is also owned by netsaint:netsaint... the docs said nobody:nscmd - I
wonder if that has anything to do with it. Apache is running as
nobody/nogroup, and members of the nscmd group are netsaint, nobody.


sh-2.05# ls -laF
total 977
drwxrwxr-x    4 netsaint netsaint      280 Aug 13 17:09 ./
drwxr-xr-x    9 netsaint netsaint      216 Jun  1 23:33 ../
drwxrwxr-x    2 netsaint netsaint       48 Apr 22 22:38 archives/
-rw-rw-r--    1 netsaint users          60 Aug 13 17:09 comment.log
-rw-r--r--    1 netsaint netsaint        6 Aug 13 01:53 netsaint.lock
-rw-r--r--    1 netsaint netsaint   965676 Aug 13 17:09 netsaint.log
-rw-r--r--    1 root     root          338 Aug 13 17:07 perms.sh
drwxrwsr-x    2 netsaint nscmd          80 Aug 13 17:09 rw/
-rw-rw-r--    1 netsaint users        9761 Aug 13 17:09 status.log
-rw-r--r--    1 netsaint netsaint     6837 Aug 13 17:09 status.sav
sh-2.05# cd rw/
sh-2.05# ls -laF
total 4
drwxrwsr-x    2 netsaint nscmd          80 Aug 13 17:09 ./
drwxrwxr-x    4 netsaint netsaint      280 Aug 13 17:09 ../
-rw-r--r--    1 nobody   nscmd          63 Aug 13 17:09 netsaint.cmd
sh-2.05#


----- Original Message -----
From: "Bishop, Dean" <dean.bishop at tcdsb.org>
To: "'Jonathan Nichols'" <jnichols at pbp.net>
Cc: <nagios-users at lists.sourceforge.net>
Sent: Tuesday, August 13, 2002 2:09 PM
Subject: RE: [Nagios-users] external commands


> yeah, permissions could be fine but the file type is wrong.
>
> rm the file /usr/local/netsaint/var/rw/netsaint.cmd
> then restart netsaint.  This should create the file again (doing an 'll
> /usr/local/netsaint/var/rw' will give you:
> prw-rw---- 1 netsaint netsaint 0 Aug 13 16:47
> netsaint.cmd
> ^
> note the leading character.  this indicates the type of file (p for pipe)
>
> if it is not created check the permissions on the /usr/local/netsaint/var
> and /usr/local/netsaint/var/rw folders.  Also check
> /usr/local/netsaint/etc/netsaint.cfg and ensure that:
> check_external_commands=1
>
> hth,
> dean
>
> -----Original Message-----
> From: Jonathan Nichols [mailto:jnichols at pbp.net]
> Sent: Tuesday, August 13, 2002 4:27 PM
> To: Bishop, Dean
> Subject: Re: [Nagios-users] external commands
>
>
> It's not? Uh oh. Something is wrong, then.. here's what it has..
> netsaint at dumpster:/usr/local/netsaint/var/rw> cat netsaint.cmd
> [1029230649] ADD_HOST_COMMENT;cheese;1;jnichols;Test
> netsaint at dumpster:/usr/local/netsaint/var/rw>
>
> If I request any other external command, the command will overwrite
whatever
> is currently in the netsaint.cmd file, but won't actually process it.
>
> I think the permissions are correct..
> netsaint at dumpster:/usr/local/netsaint/var/rw> ls -laF
> total 4
> drwxrwsrwx    2 netsaint nscmd          80 Aug 13 02:16 ./
> drwxrwxr-x    4 netsaint netsaint      256 Aug 13 13:26 ../
> -rw-r--r--    1 nobody   nscmd          54 Aug 13 02:24 netsaint.cmd
> netsaint at dumpster:/usr/local/netsaint/var/rw>
>
> The docs said that the /var/rw directory needed to be owned by
> nobody:nscmd..
>
> ----- Original Message -----
> From: "Bishop, Dean" <dean.bishop at tcdsb.org>
> To: "'Jonathan Nichols'" <jnichols at pbp.net>
> Sent: Tuesday, August 13, 2002 11:45 AM
> Subject: RE: [Nagios-users] external commands
>
>
> > ?? sitting in netsaint.cmd??
> >
> > this is not a regular file.  It is created automatically when you start
> > Netsaint and it accepts commands FIFO.
> >
> > it sounds like you are appending a regular file.  Is this accurate or
have
> i
> > misread your e-mail??
> >
> >
> >
> > -----Original Message-----
> > From: Jonathan Nichols [mailto:jnichols at pbp.net]
> > Sent: Tuesday, August 13, 2002 2:30 PM
> > To: nagios
> > Subject: [Nagios-users] external commands
> >
> >
> > Greetings all,
> >     I'm actually using Netsaint 0.0.7 still.. question about external
> > commands. It's only worked once. I don't get any errors from the web
page,
> > and it tells me that it was successful, but the command never happens.
It
> > just sits in the /usr/local/netsaint/var/rw/netsaint.cmd file and never
> gets
> > processed. I've tried restarting netsaint, and as far as I can tell, the
> > permissions are correct because it's able to write the netsaint.cmd
file.
> >
> > Is there anything in particular that I should be looking at? I've
checked
>
> > Google but can't find anything different than what I've already tried.
:(
> >
> > Thanks for any assistance..
> >
> > -Jonathan
> >
> >
> >
> >
> > -------------------------------------------------------
> > This sf.net email is sponsored by: Dice - The leading online job board
> > for high-tech professionals. Search and apply for tech jobs today!
> > http://seeker.dice.com/seeker.epl?rel_code=31
> > _______________________________________________
> > Nagios-users mailing list
> > Nagios-users at lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/nagios-users
> >
>




-------------------------------------------------------
This sf.net email is sponsored by: Dice - The leading online job board
for high-tech professionals. Search and apply for tech jobs today!
http://seeker.dice.com/seeker.epl?rel_code=31




More information about the Users mailing list