Ad Widget

Collapse

What is a good way to set a trigger that checks for internet connectivity?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • vic
    Member
    • Jul 2013
    • 58

    #1

    What is a good way to set a trigger that checks for internet connectivity?

    I want to set up a trigger dependency that requires an internet connectivity trigger indicating everything is normal. If the trigger is not tripped (internet available) then other triggers work as normal. If internet is not available then unavailable triggers from monitored servers will all be false positives so I want to block them.

    I would think this is a fairly common scenario so perhaps there are some tried and true examples of how to do this. First things that came to mind was to icmp check google nameservers and or http availability of their landing page. Unavailability of those things are rare and the odds of that happening at the same time as a critical alarm are almost nil.
    Last edited by vic; 11-11-2015, 18:01.
  • vic
    Member
    • Jul 2013
    • 58

    #2
    What I ended up doing is setting up a Host called "network check". In that Host I created 2 Items. One is simple icmp check of Google DNS 8.8.8.8 and the other OpenDNS 208.67.220.220.

    I then created a trigger that tests for both Google and OpenDNS icmp failing (test every 50seconds, trigger if fail more than 1 time in 3 minutes). So if both are not working then there is definitely no network connectivity.

    Then I added that trigger as a dependency to my Linux OS Template critical event which all my servers are using.

    So now if the trigger than looks for OpenDNS and Google DNS both not working indicates a problem, all my critical triggers are blocked because it is assumed there is no network connectivity. Not totally fullproof because even a high packet loss situation may pass the icmp test but cause false positives on server offline tests using zabbix agent. Better than what I had before which was nothing.

    I verified everything by creating an artificial incoming network failure. So seems to work the way it's supposed to.
    Last edited by vic; 11-11-2015, 20:16.

    Comment

    • evertonco
      Member
      • Aug 2014
      • 75

      #3
      I'm using web scenario feature to test this. More specifically to web scenarios: first checking access to a national webpage and second checking access to a international webpage.

      So, i can create another trigger to verify if my two previous triggers is on PROBLEM state at the same time.

      Comment

      • vic
        Member
        • Jul 2013
        • 58

        #4
        Originally posted by evertonco
        I'm using web scenario feature to test this. More specifically to web scenarios: first checking access to a national webpage and second checking access to a international webpage.

        So, i can create another trigger to verify if my two previous triggers is on PROBLEM state at the same time.
        That sounds similar. Webscenarios just uses http instead of icmp. I suppose either one should do the trick.

        Comment

        • evertonco
          Member
          • Aug 2014
          • 75

          #5
          Yes. But webscenarios performs a complete network connectivity (reaching state, DNS query and correct response) for my users.

          Comment

          • vic
            Member
            • Jul 2013
            • 58

            #6
            I started having problems with DNS from these 2 servers a couple weeks after I did this. Only Google DNS. Could have been a coincidence. However about 24 hours after I disabled the nameserver checking DNS started working again. So the google nameservers might have started to rate limit me.

            I switched to http checking with web scenario as someone else suggested.

            How I did it was:

            *Create a Host called "Network connectivity checks"
            *Create an Application called "Check network"...this step might not be necessary
            *Create 2 web scenarios. In my case it's "Availability of Google" and "Availability of Yahoo"
            *In each scenario create a "step" with the URL and check for status code "200"
            *Create a trigger called "Is Yahoo or Google accessible". Here is what my trigger expression looks like

            {Network connectivity checks:web.test.fail[Availability of Google].count(5m,1)}>1 and {Network connectivity checks:web.test.fail[Availability of Yahoo].count(5m,1)}>1
            The "and" means that both websites have to be inaccessible for this test to fail. The ".count(5m,1)}>1" is a way to avoid flapping. If the checks are intermittent from one minute to the next this rule will continue to work if the result is more than one failure in the last 5 minutes.

            It would be nice if Zabbix created a page with a bunch of examples like these. It took a lot of head scratching and trial and error to come up with this expression since there are so few examples around. Unless you do this quite often, creating expressions is not all that straight forward for most people.
            Last edited by vic; 28-11-2015, 19:23.

            Comment

            Working...