Kaseya Community

Text string in web page monitor

This question is not answered

We are having a strange issue with a web page monitor in KNM5 - lastest build. We point the monitor to a status.jspx page which contains the text "System Status is OK" with the monitor set to alert if this string is not found.


The monitor is failing straight away saying it cant find the text string although its clearly there on the web-page. If i change the tested string to "System Status" then it works - as soon as i add "is OK" it fails. If i try using "is OK" on its own that also fails.


We have other web monitors that use the text string "Servers are OK" without any issues. Any ideas?

All Replies
  • Can you post how the HTML part looks like? Is there a line break in between the words somewhere? Any extra blankspace? I did a simple test, creating a html page looking like this:

    <html>

    <head><title>System Status</title></head>

    <body>

    System Status is OK

    </body>

    </html>

    KNM reports correctly on this that the string was found. If I on the other hand do it like below, it will fail:

    <html>

    <head><title>System Status</title></head>

    <body>

    System Status

    is OK

    </body>

    </html>

  • Here is the body of the web page. It was witten by one of our DEV's - i'm the one just trying to report on it :-)

    <body style="margin:10px 10px 10px 10px;" >

               <ice:panelGrid  styleClass="statusPage" cellpadding="4" rendered="#{statusBean.display != 'inline'}">

                    <ice:outputText  styleClass="statusPage" value="#{statusBean.serverVersion}" style="font-weight:bold;" />

                    <ice:outputText  styleClass="statusPage" value="Current Time = #{statusBean.currentTime}"  style="font-weight:bold;"/>

                    <ice:panelGroup>

                       <ice:outputText styleClass="statusPage" escape="false" value="System Status is "  style="font-weight:bold;" />

                       <ice:outputText styleClass="status#{statusBean.lastStatus}" value=" #{statusBean.lastStatus}" />

                    </ice:panelGroup>

                    <ice:outputText styleClass="statusPage" escape="false" value="#{statusBean.memoryUsage}" />

                    <ice:outputText styleClass="statusPage" escape="false" value="#{statusBean.sessions}"  />

                    <ice:outputText styleClass="status#{statusBean.lastStatus}" escape="false" value="#{statusBean.lastStatusMsg}" />

               </ice:panelGrid>

               <ice:panelGrid  styleClass="statusPage" cellpadding="0x" rendered="#{statusBean.display == 'inline'}">

                   <ice:outputLink  styleClass="statusPage" value="http://#{statusBean.pathInfo}/status.jspx" style="font-weight:bold;" >#{statusBean.pathInfo}</ice:outputLink>

                    <ice:outputText  styleClass="statusPage" value="#{statusBean.serverVersion}" />

                    <ice:outputText  styleClass="statusPage" value="Current Time = #{statusBean.currentTime}"  />

                    <ice:panelGroup>

                       <ice:outputText styleClass="statusPage" escape="false" value="System Status is "   />

                       <ice:outputText styleClass="status#{statusBean.lastStatus}" value=" #{statusBean.lastStatus}"  />

                    </ice:panelGroup>

                    <ice:outputText styleClass="statusPage" escape="false" value="#{statusBean.sessionCount}" />

                    <ice:outputText styleClass="status#{statusBean.lastStatus}" escape="false" value="#{statusBean.lastStatusMsg}" />

               </ice:panelGrid>

           </body>

  • I'm not a Java developer myself, but that looks a bit like it's the source code for the script? How does the actual HTML look like in a browser?

    I do see, though, that there seems to be a line break between "System status is " and the actual status, that is one a couple of rows below. If that is the case, then it won't work to monitor for the string "System status is OK" since there is no clear text line with that.

  • OK thanks. I managed to get this to work by searching for the string >OK< which does appear in the HTML and is distinct enough for our purposes.