Page 2 of 6

Re: Nagiosgraph: JavaScript is disabled. nagiosgraph.js is n

Posted: Thu Sep 29, 2016 6:54 am
by mksmr
(edit: link fixed)

It's here:
https://sourceforge.net/p/nagiosgraph/d ... /1bcaa81e/
Here's the op's last post on the matter (from a local copy on my computer):
I solved the problem !!!

A wrong check , put "bad" character in the nagios performance field

Nagiograph was created a file like this
UX_Check_JBO_HCMP0_BOP_A_web___exception%20occurred%3A%20javax.management.AttributeNotFoundException%3A%20JBAS014749%3A%20Operation%20handler%20failed%3A%20null.%20See%20the%20log%20file%20for%20error%20details.%3B45%3B50%20JBO002_HCMP0_A.rrd

When show.cgi attempt to read this file ... "became crazy" and give the error

JavaScript is disabled.
nagiosgraph.js is not installed or wrong version

I disabled the check and I removed the file and now ALL WORK FINE !!!

Re: Nagiosgraph: JavaScript is disabled. nagiosgraph.js is n

Posted: Thu Sep 29, 2016 4:25 pm
by tmcdonald
The only bad character I could think of would be a | or possibly a ; or ! in the wrong spot.

Re: Nagiosgraph: JavaScript is disabled. nagiosgraph.js is n

Posted: Mon Oct 24, 2016 10:53 am
by mksmr
Just wondered if this could be a pointer:

Code: Select all

# tail -f /var/log/httpd/error_log

[Mon Oct 24 16:42:46.818165 2016] [cgi:error] [pid 21318] [client 192.168.1.120:56563] AH01215: Mon Oct 24 16:42:46 2016 showgraph.cgi 50910 critical Cannot write to '/var/nagios/nagiosgraph-cgi.log', using STDERR instead, referer: http://monitor/nagios/cgi-bin/show.cgi?host=09XXXXX&service=FS
As a matter of fact, the corresponding file var/nagios/nagiosgraph-cgi.log had been moved. I have replaced it now, waiting for more tries to write to the file.

Re: Nagiosgraph: JavaScript is disabled. nagiosgraph.js is n

Posted: Mon Oct 24, 2016 11:04 am
by dwhitfield
Do you get this error with JS allowed in the browser or only when it is disabled? I am assuming when it is disabled, but wondering because of
Both error messages did not show up in Firefox on OpenBSD.

Re: Nagiosgraph: JavaScript is disabled. nagiosgraph.js is n

Posted: Mon Oct 24, 2016 11:07 am
by mksmr
dwhitfield wrote:wondering because of
Both error messages did not show up in Firefox on OpenBSD.
Just checked that out... it's wrong. It DOES appear in BSD too. Sorry about the confusion.

Re: Nagiosgraph: JavaScript is disabled. nagiosgraph.js is n

Posted: Mon Oct 24, 2016 12:27 pm
by rkennedy
Are your performance handlers setup for the new paths? Perhaps a grep -R 'nagiosgraph-cgi.log' / may help to identify what's writing improperly.

Re: Nagiosgraph: JavaScript is disabled. nagiosgraph.js is n

Posted: Tue Oct 25, 2016 1:08 am
by mksmr
The file had been deleted altogether with the assumption that a new one would be created - which hasn't happened. I have created a new empty file in the same place now. Strange enough, it's size is still zero and Nagios apparently hasn't attempted to write to it yet. At least it hasn't complained about the missing file in 12 hours. Strange...

Re: Nagiosgraph: JavaScript is disabled. nagiosgraph.js is n

Posted: Tue Oct 25, 2016 8:16 am
by mksmr
Raised the debug level and nagiosgraph-cgi.log is now being written to. This problem was unrelated. The error messages

Code: Select all

JavaScript is disabled.
nagiosgraph.js is not installed or wrong version.
remain.

Re: Nagiosgraph: JavaScript is disabled. nagiosgraph.js is n

Posted: Tue Oct 25, 2016 11:02 am
by rkennedy
What are the properties on the file? You should be able to check with ls -al nagiosgraph-cgi.log.

Have you tried reinstalling nagiosgraph, and verifying all of the settings once again at all?

Re: Nagiosgraph: JavaScript is disabled. nagiosgraph.js is n

Posted: Wed Oct 26, 2016 2:24 am
by mksmr
What are the properties on the file?
I think the trouble with that file was a dead end altogether and it's not related to the original problem. It's been fixed, but the original problem remains.

Currently I'm a bit stuck now, and indeed close to dumping the whole thing altogether and rebuilding it from scratch. Still I wonder what's wrong. I am very positive that I never changed anything in the configuration. Maybe a background package update broke something. What's really confusing is that so far I cannot see anything in any logfile I'm aware of. The way I see it, it should be running. It just isn't.