netsaint external commands

Gerald Combs gerald at ethereal.com
Thu May 30 15:50:02 CDT 2002


The external command CGI needs to be able to create/open and write to
/usr/local/netsaint/var/rw/netsaint.cmd.  Therefore the "rw" directory
needs to be writable by your web server user.  My system is set up as
follows:

  - Apache is run as user "web", group "web"

  - /usr/local/netsaint/var/rw has the following ownership and
    permissions:

    drwxrwxr-x   2 netsaint netsaint      512 May 29 12:45 rw

  - The user "web" is a member of the group "netsaint".

You might try making sure "apache" is a member of the nscmd group, and
that the rw directory has group write access.  According to the docs at
http://www.netsaint.org/docs/0_0_7/commandfile.html the directory should
be group-sticky as well, but it works without the sticky bit on my system.

You can verify that the group and directory permissions are set up
correctly by su'ing to the apache user and running

  touch /usr/local/netsaint/var/rw/test.file

If it works, the external commands should work as well.  Note that you may
need to restart Apache for the group membership change to take effect.

On Thu, 30 May 2002, Eric R. wrote:

> Good morning Gerald,
> 
> I was wondering if you had gotten the external commands working in netsaint.
> 
> Namely, the:
> 
> "Disable checks for this host" and the "Disable notifications for this 
> host" links available in netsaint as you drill down into the various pages.
> 
> I keep getting "Error: Could not open command file 
> '/usr/local/netsaint/var/rw/netsaint.cmd' for update!
> 
> The permissions on the external command file and/or directory may be 
> incorrect. Read the FAQs on how to setup proper permissions.
> 
> An error occurred while attempting to commit your command for processing..."
> 
> I have gone through all of the docs for setting thses permissions up 
> several times, and I don't have a clue what I'm doing wrong.
> 
> The rw directory (under /usr/local/netsaint/var) has a user of netsaint 
> and a group of nscmd....the rw directory has the sticky bit set (I 
> think...it has a capital S in the permissions) netsaint.cmd file is 
> being created with a user of netsaint and group of nscmd and is rw, rw. 
>   So, at this point I am clueless.
> 
> I've used the htpasswd command to add myself, apache (the user httpd 
> runs under) to the htpassword.users file in /usr/local/netsaint/etc.
> 
> Also the netsaint.log reports:
> 
> Error: Could not create external command file as named pipe: (13) -> 
> Permission denied
> [1022769306] Bailing out due to errors encountered while trying to open 
> the external command file for reading... (PID=25102)
> 
> But, like I said, I thought the permissions were correct.
> 
> Any help you could provide would be appreciated.
> 
> If you need any more info, please let me know.
> 
> TIA,
> Eric
> 
> P.S.  Included to this list, incase anyone else might know.  Thanks.
> 




More information about the Kclug mailing list