Ad Widget

Collapse

WEB monitoring howto ?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Philippe
    Member
    • Oct 2004
    • 77

    #1

    WEB monitoring howto ?

    hello,

    i have zabbix 1.4.1 with WEB monitoring enabled.
    the only thing is that i don't know how it works...
    how can i monitor a static site ? let's say google to test ?

    in web application ==> just write something like web ?
    name ==> internet ?
    agent ==> which one do i have to choose ??

    steps
    ==> name ==> google
    url ==> www.google.com

    and that's it ?
    should it work like that ?
    doesn't work for me but i am probably doing things wrong.
    could someone send me on the right track please ?

    thnx,
    Ph.
  • unilogic
    Junior Member
    • Jul 2007
    • 6

    #2
    Pretty much how it works. You do need to put in a respone code typically (200 is OK) to check that the page loaded correctly if thats what you're trying todo.

    I'd love to know what the Required field is used for though. It'd be great if the manual actually had a how-to on this section.

    I'm hoping I can match a string in the middle of the page that is a result of a search. Anyone know if this is possible with web monitoring.

    Thanks,
    Ben

    Comment

    • Philippe
      Member
      • Oct 2004
      • 77

      #3
      in my test i get the message:

      Failed on "www.google.be" [1 of 1] Error: couldn't resolve host name

      in the logging i get:
      Error doing curl_easy_perform [couldn't resolve host name]

      my zabbix installation command was:
      ./configure --enable-server --with-mysql --with-net-snmp --with-jabber --with-libcurl

      any idea ?
      thnx.
      Last edited by Philippe; 03-07-2007, 08:56.

      Comment

      • unilogic
        Junior Member
        • Jul 2007
        • 6

        #4
        Can the server resolve www.google.be normally? i.e. try pinging it. Does Zabbix by chance need you to put http:// in the link?

        Comment

        • Philippe
          Member
          • Oct 2004
          • 77

          #5
          we are behind a firewall but my zabbix server can access internet completely.
          a ping is not allowed but i didn't thought that it was done with a ping ?.

          i added
          -x 10.10.10.10:80 (not real address)
          in /root/.librc and with that i could perform the following:
          curl www.google.com

          and i received a lot of data on the screen so this shows that it works with the proxy ?

          in zabbix log file i still get:

          Error doing curl_easy_perform [couldn't resolve host name]
          Last edited by Philippe; 03-07-2007, 10:18.

          Comment

          • Alexei
            Founder, CEO
            Zabbix Certified Trainer
            Zabbix Certified SpecialistZabbix Certified Professional
            • Sep 2004
            • 5654

            #6
            If the Required string in non empty, than ZABBIX checks if a retrieved page contains it. It won't process further steps if content of the page has no this string.
            Alexei Vladishev
            Creator of Zabbix, Product manager
            New York | Tokyo | Riga
            My Twitter

            Comment

            • JustinM
              Junior Member
              • Jul 2007
              • 9

              #7
              Hi Alexei,

              Does the Required string accept regular expressions?

              Thanks,
              Justin.

              Comment

              • Alexei
                Founder, CEO
                Zabbix Certified Trainer
                Zabbix Certified SpecialistZabbix Certified Professional
                • Sep 2004
                • 5654

                #8
                Yes, it does accept Posix style regular expression!
                Alexei Vladishev
                Creator of Zabbix, Product manager
                New York | Tokyo | Riga
                My Twitter

                Comment

                • JustinM
                  Junior Member
                  • Jul 2007
                  • 9

                  #9
                  Fantastic, thanks very much Alexei.

                  Comment

                  • bbrendon
                    Senior Member
                    • Sep 2005
                    • 870

                    #10
                    What about referrers? Can this be added to make it seem more like a real browser?
                    Unofficial Zabbix Expert
                    Blog, Corporate Site

                    Comment

                    • psedo
                      Junior Member
                      • Aug 2007
                      • 10

                      #11
                      How to make a scenario?

                      Hi,

                      I'm trying to make a scenario, but I'm getting an error !

                      server log :

                      Error doing curl_easy_perform [couldn't connect]


                      config of the scenario on Zabbix_server:

                      application = general
                      name = relou
                      agent = mozilla 1.5 on Linux (the version of the browser is important ?)
                      status = active
                      variable = none

                      steps :
                      name = google_fr
                      URL = http://www.google.fr
                      post = none
                      timeout = 15
                      required = none
                      code = 200


                      Thank's in advance !

                      Comment

                      • oliverm
                        Senior Member
                        • May 2006
                        • 155

                        #12
                        in case you still have the problem its because of the http:// at the start of the URL. I've just recreated it here, and removing the HTTP:// fixes the problem.

                        Comment

                        • SMB
                          Member
                          • Sep 2007
                          • 30

                          #13
                          Just to add to the question, is there a way I can display this on a screen. Say I have 100 web sites to monitor, is it possible to have a display that will say x number of sites down or something along those lines?

                          Comment

                          • psedo
                            Junior Member
                            • Aug 2007
                            • 10

                            #14
                            Originally posted by oliverm
                            in case you still have the problem its because of the http:// at the start of the URL. I've just recreated it here, and removing the HTTP:// fixes the problem.
                            Thanks for your answer !
                            I removed "http://" but I always have the same error :
                            In web interface = Failed on "test_google" [1 of 1] Error: couldn't connect
                            in server log = Error doing curl_easy_perform [couldn't connect]


                            In steps part, what 'status code' do it means ?
                            Can you put a complete configuration (like I do) which it is working for you ?


                            Thanks in advance.
                            Last edited by psedo; 26-09-2007, 12:12.

                            Comment

                            • SMB
                              Member
                              • Sep 2007
                              • 30

                              #15
                              Originally posted by psedo
                              In steps part, what 'status code' do it means ?
                              Expected HTTP/HTTPS status returned. 2xx are generally successes, 4xx are various errors like File not Found (404) or authentication problems (403 Forbidden), 5xx are server errors (500 Internal Server Error).

                              What the status is saying is if you get this return (200) everything is good, if not raise an alarm.

                              Comment

                              Working...