Ad Widget

Collapse

Web check return page

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • nicolasg
    Member
    • Apr 2011
    • 50

    #1

    Web check return page

    Hi All,

    I have created a Web check scenario and step that successfully checks the availability of a page and triggers an alerts if something is wrong.

    I would like to know if there is any way I can include in the mail alert that is sent the content of the return page in case the scenario is not successful ?

    Thanks in advance.
  • Yello
    Senior Member
    • Apr 2011
    • 309

    #2
    Hi,
    Perhaps you could describe the url as a set of macros?


    Regards,
    David

    Comment

    • nicolasg
      Member
      • Apr 2011
      • 50

      #3
      Hi David,

      Thanks for the reply. I don't really understand what do you mean and how can you do that..

      I want to sent the page content in case of a trigger, can this be done using macros ?

      Regards,
      Nicolas.

      Comment

      • Yello
        Senior Member
        • Apr 2011
        • 309

        #4
        Hi,
        I assume you are, or have been, configuring actions to handle this. In the default action configuration you'll see that default builtin macros are referenced to refer to specific zabbix variables. You can also add your own mcros to deine other variables that you want to use...

        Possibly an even better option would be to define the url(s) that concern you in the trigger comment. Then when you configure your action refer to {TRIGGER.URL} in order to pass the URL into the message.

        For more details refer to the zabbix manual.

        Regards,
        David
        Last edited by Yello; 27-06-2011, 11:37.

        Comment

        • nicolasg
          Member
          • Apr 2011
          • 50

          #5
          Hi Dave,

          My current trigger to check if the Web check fails is {test_web1:web.test.fail[Web1_HTTP_Check_Scenario].
          last(0)}#0 and it is working fine.

          The Default message configure in all my actions is :
          """
          {TRIGGER.NAME}: {TRIGGER.STATUS}
          Last value: {ITEM.LASTVALUE}

          {TRIGGER.URL}
          """

          but for some reason I never get any values for {TRIGGER.URL}.. are you saying that the TRIGGER.URL will return the page content or I have to define my own MACRO ?

          Comment

          • Yello
            Senior Member
            • Apr 2011
            • 309

            #6
            Hi,
            That's because you haven't configurd {TRIGGER.URL}. If you go to the configured trigger you'll see a URL dialogue in the bottom half of the screen. Set it there and it should work.


            Regards,
            David

            Comment

            • nicolasg
              Member
              • Apr 2011
              • 50

              #7
              I got your point thanks, I set the URL and now I get TRIGGER.URL value in the notifications.

              However this is not what I want, I need the page content to be included in the email and not the url ... is this possible ?

              Comment

              • Yello
                Senior Member
                • Apr 2011
                • 309

                #8
                Hi,
                I've not tried that but I believe that if you search the forum you should find discussion of that subject.


                Regards,
                David

                Comment

                • nicolasg
                  Member
                  • Apr 2011
                  • 50

                  #9
                  Yeah I found discussions but either the solution was to user user-parameters scrips or there were no answers and that's why I created a new thread...

                  Anyway, I appreciate your help.

                  Comment

                  Working...