Re: [Nagios-users] current_state value in status.dat file

2011-03-17 Thread Rai Ricafrente
Thanks for pointing the doc. I've been going through that and I guess I was
looking for the part where it says that DOWN = 1 and not 2.


On Thu, Mar 17, 2011 at 3:40 PM, Giacomo Montagner wrote:

> On Thu, 17 Mar 2011 14:57:08 +0800
> Rai Ricafrente  wrote:
>
> > I am looking at the status.dat file and I noticed that the current_state
> is
> > =1 even when the host is down and is in critical state. I assume that if
> a
> > host is down, the current_state should be =2.
>
> It's probably because hosts can be in only 3 states:
>
> UP=0
> DOWN=1
> UNREACHABLE=2 (
> http://nagios.sourceforge.net/docs/3_0/networkreachability.html)
>
> Giacomo
>
>
>
>
> --
> Colocation vs. Managed Hosting
> A question and answer guide to determining the best fit
> for your organization - today and in the future.
> http://p.sf.net/sfu/internap-sfd2d
> ___
> Nagios-users mailing list
> Nagios-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagios-users
> ::: Please include Nagios version, plugin version (-v) and OS when
> reporting any issue.
> ::: Messages without supporting info will risk being sent to /dev/null
>
--
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null

Re: [Nagios-users] current_state value in status.dat file

2011-03-17 Thread Giacomo Montagner
On Thu, 17 Mar 2011 14:57:08 +0800
Rai Ricafrente  wrote:

> I am looking at the status.dat file and I noticed that the current_state is
> =1 even when the host is down and is in critical state. I assume that if a
> host is down, the current_state should be =2.

It's probably because hosts can be in only 3 states: 

UP=0
DOWN=1
UNREACHABLE=2 (http://nagios.sourceforge.net/docs/3_0/networkreachability.html)

Giacomo



--
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


[Nagios-users] current_state value in status.dat file

2011-03-17 Thread Rai Ricafrente
I am looking at the status.dat file and I noticed that the current_state is
=1 even when the host is down and is in critical state. I assume that if a
host is down, the current_state should be =2. I am not sure how Nagios sets
the current_status but in my case, the host is definitely off:

admin1@serverr1:~> ping userver02
PING userver02.localhost (192.168.0.11) 56(84) bytes of data.

--- userver02.localhost ping statistics ---
7 packets transmitted, 0 received, 100% packet loss, time 6012ms

So why does the status.dat file say that the current_status=1? Does it mean
that the host is in Warning state only, and not in Critical as opposed to
what I am seeing in the web console? Anyway, I am bothered by this because I
am using the check_summary.pl plugin (
http://exchange.nagios.org/directory/Plugins/Network-and-Systems-Management/Nagios/check_summary/details)
and
it reads the status.dat file.

Btw, the status.dat file looks like this:

hoststatus {
host_name=userver02
modified_attributes=0
check_command=check-host-alive
check_period=24x7
notification_period=24x7
check_interval=5.00
retry_interval=1.00
event_handler=
has_been_checked=1
should_be_scheduled=1
check_execution_time=2.114
check_latency=0.239
check_type=0
current_state=1
last_hard_state=1
last_event_id=505
current_event_id=509
current_problem_id=232
last_problem_id=0
plugin_output=CRITICAL - userver02.localhost: rta nan, lost 100%
long_plugin_output=
performance_data=rta=0.000ms;800.000;1000.000;0; pl=100%;80;100;;
rtmax=0.000ms rtmin=0.000ms
last_check=1300344149
next_check=1300344459
check_options=0
current_attempt=1
max_attempts=2
current_event_id=509
last_event_id=505
state_type=1
last_state_change=1299383163
last_hard_state_change=1299383163
last_time_up=0
last_time_down=1300344159
last_time_unreachable=0
last_notification=1300344079
next_notification=1300347679
no_more_notifications=0
current_notification_number=267
current_notification_id=2857
notifications_enabled=1
problem_has_been_acknowledged=0
acknowledgement_type=0
active_checks_enabled=1
passive_checks_enabled=1
event_handler_enabled=1
flap_detection_enabled=1
failure_prediction_enabled=1
process_performance_data=1
obsess_over_host=1
last_update=1300344223
is_flapping=0
percent_state_change=0.00
scheduled_downtime_depth=0
}
--
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null