This discussion has been locked. The information referenced herein may be inaccurate due to age, software updates, or external references.
You can no longer post new replies to this discussion. If you have a similar question you can start a new discussion in this forum.

Calculating the Real Availability? (Maintenance Mode)

I have a serious issue with the availability report calculation method in Orion. I don't want my unmanage devices to decrease availability. I have to use unmanage for nodes under maintenance. According to Orion (by design) it doesn't matter whether it is down or unmanaged for the availability. This feature is essential for us.

Suggestions or workarounds are welcome.

 

Quote from a user in thwack

 It would also be nice if the "downtime" during the maintenance mode can optionally either be included or excluded in reports (availability reports).

  • Nobody answered my question :(. Can you please move to the NPM Feature request section?

    Thanks.

  • I created a report once that polled the database table that stores the response time for pings, to create a list of the nodes that most recently went down, and when they last responded.  I don't have it in front of me at the moment, but you could do something similar if it were really essential.   It would be quite a bit more complex though so you'd have to really want it.

  • Here is the report that I made that tells me when I last saw the nodes that are down.  It queries the ResponseTime table for the response times, and then gets the periods that had less than 100% packet loss, and returns that.

    You might be able to get all of the PercentLoss with associated DateTime for a given node in a give time period, and then iterate through them adding and subtracting from the uptime.  I'm not entirely sure if the math could be performed in the SQL itself, but it would be pretty easy to do in a spreadsheet if you exported all of the data.

    Of course, this is all assuming you're talking about getting the data in a report and not the node details page.

    WITH LastResponse (NodeId, MaxDate, PercentLoss)
    AS (
    SELECT
    ResponseTime.NodeID,
    MAX(DateTime) MaxDate,
    ResponseTime.PercentLoss
    
    FROM ResponseTime
    
    GROUP BY NodeID, PercentLoss
    )
    
    SELECT TOP 10
    Nodes.NodeID,
    Nodes.Caption,
    MAX(LastResponse.MaxDate) MaxTime
    
    FROM LastResponse
    LEFT JOIN Nodes ON (Nodes.NodeID=LastResponse.NodeID AND Nodes.Status = 2)
    
    WHERE (Nodes.Status = 2)
    AND (LastResponse.PercentLoss < 100)
    
    GROUP BY Nodes.NodeID, Nodes.Caption
    
    ORDER BY MaxTime Desc