Page 1 of 2

Monitor WIFI drops

Posted: Fri Nov 20, 2015 8:22 am
by HenkR
Hi,

in my home, my WIFI signal drops from time to time.
It lasts only 20 seconds to 5 minutes and then it comes back.
I would like to monitor these drops.

I have a Raspbian Pi with NagiosPi that's connected trough WIFI.
I have configured one host in Nagios: my router which is monitored by Ping.

I was thinking of using the report "trends" to watch when it was offline, but this report shows it's always online altough the host goes down from time to time...

What am I doing wrong?

Is there a better way to do it?

Re: Monitor WIFI drops

Posted: Fri Nov 20, 2015 10:53 am
by rkennedy
I believe reducing the time on this check should provide you the accurate results you're looking for. Look for the host / service you're using to monitor that service, and add into it -

Code: Select all

check_interval 1

Re: Monitor WIFI drops

Posted: Fri Nov 20, 2015 11:09 am
by eloyd
Another thought is to monitor your system log to see if there is text matching some sort of wifi drop or rediscover. That way, you're not relying on catching it in the act, but instead are relying on the system reporting it in the logs, and you seeing it there.

Re: Monitor WIFI drops

Posted: Fri Nov 20, 2015 1:07 pm
by jolson
In addition to reducing your check_interval, you'll probably want a critical right away:

Code: Select all

max_check_attempts              1
-or if you expect dropped packets once in awhile:

Code: Select all

max_check_attempts              2

Re: Monitor WIFI drops

Posted: Tue Nov 24, 2015 11:53 am
by HenkR
rkennedy wrote:I believe reducing the time on this check should provide you the accurate results you're looking for. Look for the host / service you're using to monitor that service, and add into it -

Code: Select all

check_interval 1

It was allready set to 1.

Does this mean 1 minute?

Re: Monitor WIFI drops

Posted: Tue Nov 24, 2015 12:11 pm
by HenkR
eloyd wrote:Another thought is to monitor your system log to see if there is text matching some sort of wifi drop or rediscover. That way, you're not relying on catching it in the act, but instead are relying on the system reporting it in the logs, and you seeing it there.
Good idea, thanks

Re: Monitor WIFI drops

Posted: Tue Nov 24, 2015 12:15 pm
by rkennedy
HenkR wrote:
rkennedy wrote:I believe reducing the time on this check should provide you the accurate results you're looking for. Look for the host / service you're using to monitor that service, and add into it -

Code: Select all

check_interval 1

It was allready set to 1.

Does this mean 1 minute?
Yes. @eloyd made a good comment - if a one minute check_interval isn't good enough then checking the logs may be more viable. Does that solution work for you?

Re: Monitor WIFI drops

Posted: Tue Nov 24, 2015 12:23 pm
by HenkR
Yes, I'm using the logs.

But there's one thing I don't understand about Nagios:

Sometimes, when I click on hosts, I see that it detected the host went down by looking at the time in the duration column.
However when I look at the trends report it shows it hasn't been down.

Re: Monitor WIFI drops

Posted: Tue Nov 24, 2015 2:10 pm
by hsmith
I think the most likely explanation would be that it is coming back up before it reaches its max check attempts.
Object Definitions wrote: This directive is used to define the number of times that Nagios will retry the host check command if it returns any state other than an OK state. Setting this value to 1 will cause Nagios to generate an alert without retrying the host check. Note: If you do not want to check the status of the host, you must still set this to a minimum value of 1. To bypass the host check, just leave the check_command option blank.
https://assets.nagios.com/downloads/nag ... .html#host

Re: Monitor WIFI drops

Posted: Thu Nov 26, 2015 3:11 pm
by HenkR
With my host, I have configured a PING service and I also have the check command check-host-alive configured.

Does this mean I am actually doing 2 checks?