Hi,
Today I saw this weird behaviour (attached)..
A check_http service check was replied with 'HTTP WARNING: HTTP/1.1 404 Not Found' but the service check remained at 'OK' status and no notifications were sent.
This is working fine for other checks.
Any ideas?
Thanks.
check_http Status OK instead of Warning
check_http Status OK instead of Warning
You do not have the required permissions to view the files attached to this post.
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: check_http Status OK instead of Warning
Can you post the full check command that this service is executing.
Also, can you run the command from the command line, and then run
and post the output.
Thanks
Also, can you run the command from the command line, and then run
Code: Select all
echo $?Thanks
Re: check_http Status OK instead of Warning
Hi,
[root@nagios ~]# /usr/local/nagios/libexec/check_http -H 10.10.1.45 -u "/url" -p 8082 -w 2 -c 5
HTTP OK HTTP/1.1 200 OK - 162 bytes in 0.004 seconds |time=0.003518s;2.000000;5.000000;0.000000 size=162B;;;0
[root@nagios ~]# echo $?
0
The service is at 'ok' status right now.
For Warning:
HTTP WARNING: - HTTP/1.1 200 OK - 0.004 second response time |time=0.004044s;0.000000;;0.000000 size=162B;;;0
[root@nagios ~]# echo $?
1
Thanks.
[root@nagios ~]# /usr/local/nagios/libexec/check_http -H 10.10.1.45 -u "/url" -p 8082 -w 2 -c 5
HTTP OK HTTP/1.1 200 OK - 162 bytes in 0.004 seconds |time=0.003518s;2.000000;5.000000;0.000000 size=162B;;;0
[root@nagios ~]# echo $?
0
The service is at 'ok' status right now.
For Warning:
HTTP WARNING: - HTTP/1.1 200 OK - 0.004 second response time |time=0.004044s;0.000000;;0.000000 size=162B;;;0
[root@nagios ~]# echo $?
1
Thanks.
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: check_http Status OK instead of Warning
If this is in the warning state and still showing green OK, I am guessing there may be some database corruption
We have a document on repairing the database
http://library.nagios.com/library/produ ... i-database
We have a document on repairing the database
http://library.nagios.com/library/produ ... i-database