4 Replies Latest reply on Feb 2, 2016 4:39 AM by tru_st

    I need to a report that shows current down servers and how long they have been down?

    codyb

      I have a report that shows all down servers, but I need to add either time it went down or how long it has been down to the report. I found something close but not exactly what I was looking for. https://thwack.solarwinds.com/docs/DOC-174729 still learning SQL query.

       

      Thanks in Advance!

       

      Update, I haven't figured out how to get IP, but I did get it working using my Custom Property of Device = Server. This will display the Server name and the hours it has been down. (still needing IP if someone can help).

       

      SELECT

       

        N.NODEID AS "ID",

        'N' AS "OBJECTTYPE",

        N.CAPTION AS "DEVICE",

        N.OBJECTSUBTYPE AS "POLLING METHOD",

        (DATEDIFF(HH,(MAX(E.EVENTTIME)), GETDATE())) AS "TIME DOWN IN HOURS"

      FROM

      NODES N

      INNER JOIN

        (EVENTS E

        INNER JOIN

        EVENTTYPES ET ON (E.EVENTTYPE = ET.EVENTTYPE))

        ON (N.NODEID = E.NETOBJECTID)

      WHERE (

      (E.NETOBJECTID = N.NODEID) AND

      (E.EVENTTYPE = 1) AND

      (N.STATUS = '2') AND

      (N.Device  = 'Server'))

      GROUP BY N.NODEID, N.CAPTION, N.OBJECTSUBTYPE