I followed the instructions in commandfile.html documentation to the letter, its still not working. <div><br></div><div>Its clearly a permissions issue between the user that the web server is running as and the user that nagios is running is.  I did create a nagcmd group where both users are a part of and set up the sticky bit, but no luck.</div>
<div><br></div><div>I am running Nginx web server, not Apache so maybe there's some kind of configuration issue that has to be dealt with, does anyone have any experience with Nginx, Nagios and the command file?</div>
<div><br></div><div>Thanks<br><br><div class="gmail_quote">On Sun, Oct 3, 2010 at 9:57 AM, Martin Melin <span dir="ltr"><<a href="mailto:mmelin@gmail.com">mmelin@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Have a look at this page from the official docs: <a href="http://nagios.sourceforge.net/docs/2_0/commandfile.html" target="_blank">http://nagios.sourceforge.net/docs/2_0/commandfile.html</a><div><br></div><div><a href="http://nagios.sourceforge.net/docs/2_0/commandfile.html" target="_blank"></a>Do as it says and things will work.</div>

<div><br></div><div>Re: your second question, just look in nagios.conf.<br><div><br></div><div><a href="http://nagios.sourceforge.net/docs/2_0/commandfile.html" target="_blank"></a>Best regards,</div><div>Martin Melin<div>
<div></div><div class="h5"><br><br><div class="gmail_quote">
On Sun, Oct 3, 2010 at 3:48 PM, Ilan Berkner <span dir="ltr"><<a href="mailto:iberkner@gmail.com" target="_blank">iberkner@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

Did not work, probably b/c I'm restarting the service as root?<div><br></div><div>Is there a way to tell under which user nagios is trying to access the nagios.cmd file?<div><div></div><div><br><br><div class="gmail_quote">

On Sun, Oct 3, 2010 at 5:03 AM, Rutger Blom <span dir="ltr"><<a href="mailto:rutger@blokje.net" target="_blank">rutger@blokje.net</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Set the sticky bit on the directory.<div><br></div><div>Rutger<br><br><div class="gmail_quote"><div><div></div><div>
On Sun, Oct 3, 2010 at 8:55 AM, Ilan Berkner <span dir="ltr"><<a href="mailto:iberkner@gmail.com" target="_blank">iberkner@gmail.com</a>></span> wrote:<br>

</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div></div><div>Hi,<div><br></div><div>New to Nagios...</div><div><br></div><div>Got everything pretty much running, except when I try to modify things using the web interface, I get this error:</div>




<div><br></div><div><span style="font-family:arial, serif;font-size:13px"><div style="font-family:arial, serif;text-align:center;color:red;font-weight:bold;font-size:12pt">
Error: Could not open command file '/usr/local/nagios/var/rw/nagios.cmd' for update!</div><p></p><p></p><div style="font-family:arial, serif;text-align:center;font-weight:bold;font-size:12pt">
The permissions on the external command file and/or directory may be incorrect. Read the FAQs on how to setup proper permissions.</div><p></p><p></p><div style="font-family:arial, serif;text-align:center;color:red;font-weight:bold;font-size:12pt">





An error occurred while attempting to commit your command for processing.</div></span></div><div><br></div><div><br></div><div>This is clearly a permission issue as when I manually change the permissions of the /rw/nagios.cmd to 777 for example, it works fine.  When the service is restarted and the pipe is recreated though, the permissions are re-set.</div>





<div><br></div><div>I am running the nginx web server, not apache.</div><div><br></div><div>SELinux is disabled.</div><div><br></div><div>The rw directory has 777 permissions and is owned by the nagios user and group.</div>





<div><br></div><div>The Nginx server runs under a different user / group and this could be the issue.  However, I tried to set up the rw directory with that user and group and still no luck.</div><div><br></div><div>Help?</div>





<br></div></div>------------------------------------------------------------------------------<br>
Start uncovering the many advantages of virtual appliances<br>
and start using them to simplify application deployment and<br>
accelerate your shift to cloud computing.<br>
<a href="http://p.sf.net/sfu/novell-sfdev2dev" target="_blank">http://p.sf.net/sfu/novell-sfdev2dev</a><br>_______________________________________________<br>
Nagios-users mailing list<br>
<a href="mailto:Nagios-users@lists.sourceforge.net" target="_blank">Nagios-users@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/nagios-users" target="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</a><br>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.<br>
::: Messages without supporting info will risk being sent to /dev/null<br></blockquote></div><br><br clear="all"><br>-- <br>Rutger Blom<br>Luzernvägen 14<br>227 38 LUND<br>Sweden<br>Tel. +46 763 46 99 44<br><a href="http://www.rutgerblom.com" target="_blank">www.rutgerblom.com</a><br>




<br><a href="http://delicious.com/rbml77" target="_blank"><img></a> <a href="http://www.facebook.com/rutgerblom" target="_blank"><img></a> <a href="http://foursquare.com/user/rutgerblom" target="_blank"><img></a> <a href="http://www.linkedin.com/in/rutgerblom" target="_blank"><img></a> <a href="http://picasaweb.google.com/rutger.blom" target="_blank"><img></a> <a href="http://twitter.com/rutgerblom" target="_blank"><img></a><br>




<br>
</div>
<br>------------------------------------------------------------------------------<br>
Start uncovering the many advantages of virtual appliances<br>
and start using them to simplify application deployment and<br>
accelerate your shift to cloud computing.<br>
<a href="http://p.sf.net/sfu/novell-sfdev2dev" target="_blank">http://p.sf.net/sfu/novell-sfdev2dev</a><br>_______________________________________________<br>
Nagios-users mailing list<br>
<a href="mailto:Nagios-users@lists.sourceforge.net" target="_blank">Nagios-users@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/nagios-users" target="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</a><br>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.<br>
::: Messages without supporting info will risk being sent to /dev/null<br></blockquote></div><br></div></div></div>
<br>------------------------------------------------------------------------------<br>
Start uncovering the many advantages of virtual appliances<br>
and start using them to simplify application deployment and<br>
accelerate your shift to cloud computing.<br>
<a href="http://p.sf.net/sfu/novell-sfdev2dev" target="_blank">http://p.sf.net/sfu/novell-sfdev2dev</a><br>_______________________________________________<br>
Nagios-users mailing list<br>
<a href="mailto:Nagios-users@lists.sourceforge.net" target="_blank">Nagios-users@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/nagios-users" target="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</a><br>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.<br>
::: Messages without supporting info will risk being sent to /dev/null<br></blockquote></div><br></div></div></div></div>
<br>------------------------------------------------------------------------------<br>
Start uncovering the many advantages of virtual appliances<br>
and start using them to simplify application deployment and<br>
accelerate your shift to cloud computing.<br>
<a href="http://p.sf.net/sfu/novell-sfdev2dev" target="_blank">http://p.sf.net/sfu/novell-sfdev2dev</a><br>_______________________________________________<br>
Nagios-users mailing list<br>
<a href="mailto:Nagios-users@lists.sourceforge.net">Nagios-users@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/nagios-users" target="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</a><br>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.<br>
::: Messages without supporting info will risk being sent to /dev/null<br></blockquote></div><br></div>