Page 1 of 1

404 Not Found

Posted: Wed Mar 11, 2015 12:37 am
by braindope
Hi,


The error below happens when i click my SQL jobs checks. It supposed to output what are my errors in my SQL
Not Found

The requested URL /nagios/sqllog/<nagios machine IP>-2015-03-11.html was not found on this server.
I'm using check_sqljob.sh as my service checks

Update:

This error is due to the fact that there is no generated file for this day in this directory /usr/local/nagios/share/sqllog/ , because there is no error recorded. How can i make the check to generate file everyday and still log the previous day error's

Re: 404 Not Found

Posted: Wed Mar 11, 2015 12:21 pm
by jdalrymple
Hi braindope

This check has a LOT of moving parts.

1) Have you verified the output of the plugin when running from the command line?
2) Have you configured the url.properties file to put the file in a real location on your server in which your nagios user has rights to write and your apache user has rights to read?
3) Have you configured your Apache to direct the browser provided URI to the proper location on your Nagios server's disk?

Like I said - lots of moving parts, and I'd say the order above is the basic troubleshooting outline to work with. Let us know.

Re: 404 Not Found

Posted: Fri Mar 13, 2015 12:50 am
by braindope
Hi jdalrymple,

Thank you for replying to my post. :D

My error occurs when there is no file generated for that day, in /usr/local/nagios/share/sqllog directory. In a sense, if there will be an SQL job failed recorded, the error that i reported will not be seen, since it can fetch a file from the directory.

Re: 404 Not Found

Posted: Fri Mar 13, 2015 1:26 pm
by jdalrymple
Do the files get created for any day or for any services, or is it not working at all?

Additionally have you already ran this service check from the command line to verify its output and also verify that when run from the command line the file is created?

What are the permissions on that sqllog folder?

Code: Select all

ll /usr/local/nagios/share/sqllog
We really need the answers to some of the questions in order to be able to further troubleshoot.