404 warnings on web content monitor

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
c.slagel
Posts: 57
Joined: Mon Dec 17, 2012 6:47 pm

404 warnings on web content monitor

Post by c.slagel »

We have a specific website content monitor that intermittently gives a "HTTP WARNING: HTTP/1.0 404 Not Found"

However, the page loads fine in a browser, no 404.

We have over a hundred of these running, and this is the only one this happens on.

Any ideas on what the issue may be?

Thanks in advance.
c.slagel
Posts: 57
Joined: Mon Dec 17, 2012 6:47 pm

Re: 404 warnings on web content monitor

Post by c.slagel »

Also, just an FYI, other sites served on the same server do not experience this, and there is an identical instance of this page running on a different server with no issues.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: 404 warnings on web content monitor

Post by abrist »

What is the full check command? When it 404s, does it ever go into a hard state?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
c.slagel
Posts: 57
Joined: Mon Dec 17, 2012 6:47 pm

Re: 404 warnings on web content monitor

Post by c.slagel »

abrist wrote:What is the full check command? When it 404s, does it ever go into a hard state?
check_xi_service_http!-s "UA-39208894-3" -f ok -I 10.1.2.237 -u "/" -p 80!!!!!!!

No, it never enters a hard state, remains as a "warning".
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: 404 warnings on web content monitor

Post by lmiltchev »

Can you show us the actual command you are running from the command line, along with the output of it, for example:

Code: Select all

[root@testbox ~]# /usr/local/nagios/libexec/check_http -H penguinsunbound.com -s "Penguins" -f ok -I 204.169.120.26 -u "/" -p 80
HTTP OK: HTTP/1.1 200 OK - 23653 bytes in 0.478 second response time |time=0.477644s;;;0.000000 size=23653B;;;0

Code: Select all

[root@testbox ~]# /usr/local/nagios/libexec/check_http -H penguinsunbound.com -s "bla-bla" -f ok -I 204.169.120.26 -u "/" -p 80
HTTP CRITICAL: HTTP/1.1 200 OK - string 'bla-bla' not found on 'http://penguinsunbound.com:80/' - 23653 bytes in 0.466 second response time |time=0.466010s;;;0.000000 size=23653B;;;0
Be sure to check out our Knowledgebase for helpful articles and solutions!
c.slagel
Posts: 57
Joined: Mon Dec 17, 2012 6:47 pm

Re: 404 warnings on web content monitor

Post by c.slagel »

lmiltchev wrote:Can you show us the actual command you are running from the command line, along with the output of it, for example:

Code: Select all

[root@testbox ~]# /usr/local/nagios/libexec/check_http -H penguinsunbound.com -s "Penguins" -f ok -I 204.169.120.26 -u "/" -p 80
HTTP OK: HTTP/1.1 200 OK - 23653 bytes in 0.478 second response time |time=0.477644s;;;0.000000 size=23653B;;;0

Code: Select all

[root@testbox ~]# /usr/local/nagios/libexec/check_http -H penguinsunbound.com -s "bla-bla" -f ok -I 204.169.120.26 -u "/" -p 80
HTTP CRITICAL: HTTP/1.1 200 OK - string 'bla-bla' not found on 'http://penguinsunbound.com:80/' - 23653 bytes in 0.466 second response time |time=0.466010s;;;0.000000 size=23653B;;;0
[root@nagios ~]# /usr/local/nagios/libexec/check_http -H 10.1.2.237 -s "UA-39208894-3" -f ok -I 10.1.2.237 -u "/" -p 80
HTTP WARNING: HTTP/1.0 404 Not Found

Like I said though, if i plug 10.1.2.237 into a browser it returns just fine.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: 404 warnings on web content monitor

Post by abrist »

Is the string that is checked part of an ajax response? If so, you may have race conditions with the check and the asynchronous ajax call . . .
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
c.slagel
Posts: 57
Joined: Mon Dec 17, 2012 6:47 pm

Re: 404 warnings on web content monitor

Post by c.slagel »

No, it's a google analytics code. We use that code to monitor all our sites and this is the only one out of a hundred that has an issue, so I doubt that's the problem.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: 404 warnings on web content monitor

Post by abrist »

You try increasing the timeout of the check, add "-t 20" to the check:

Code: Select all

 -t, --timeout=INTEGER
    Seconds before connection times out (default: 10)
This is very strange. Very intermittent. Are you also pinging this host? If so, have you noticed any odd spikes in the response time or a number of soft fails?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Locked