Nagios | Return code of 255 is out of bounds

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
vadoodc
Posts: 1
Joined: Sun Apr 03, 2016 12:39 am

Nagios | Return code of 255 is out of bounds

Post by vadoodc »

I am using Nagios for our monitoring system. Recently added plugin check_url.pl to check site availability with http response codes. Plugin is working fine but it frequently reporting an invalid response code of 255. Below is the exact message displayed on dashboard and it is disappearing automatically. It looks like some attempt is failing or getting invalid response code.

SERVICE ALERT: MAINSite ;Main site URL Check;CRITICAL;SOFT;1;(Return code of 255 is out of bounds


Here is my configuration details.

Defined command like below.

define command{
command_name url_check
command_line $USER1$/check_url.pl $ARG1$
}

Here is host configuration


define host{
use linux-server ; Inherit default values from a template
host_name MAINSite ; The name we're giving to this host
alias MAINSite ; A longer name associated with the host
address abcblabla.com ; IP address of the host
check_command check_tcp!80
}

define service{
use frequent-service
host_name MAINSite
service_description Main site URL Check
check_command url_check!abcblabla.com
}


Kindly share your thoughts/experience over this.

Attached screen shot for one event.

Thanks,
Abdul
Attachments
Nagios.PNG
Nagios.PNG (8.37 KiB) Viewed 1493 times
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: Nagios | Return code of 255 is out of bounds

Post by rkennedy »

As this is a custom plugin, we're limited to the support we can provide to it. When you see the error, does it automatically resolve itself with time? Is the webpage accessible? Next time it goes down run a curl -v "http://site.com/folder/" and post the output for us to look at.

My guess is that some other response code is being given, or perhaps the site is going down at the time.
Former Nagios Employee
Locked