cancel
Showing results for 
Search instead for 
Did you mean: 
Create Post
Level 12

How to get DPA "overview table" in Orion

On the DPA start page we have this nice overview table of how all instances are. Wouldn't it be nice to have that in an Orion view as well!

The number of widgets in Orion for DPA information is a bit limited. So is also the information in Orion database about DPA status. Almost all info for this exist though. So we created a custom table showing the "DPA Overview" in Orion

Seashore_0-1596197159110.png

 

This is how you create it:

  • Add a new "Custom Table" widget.
  • Add a "Advanced SWQL datasource" with below code

 

 

 

SELECT
    CASE  
        WHEN I.GroupId=1 THEN 'Group 1'
        WHEN I.GroupId=2 THEN 'Group 2'
        WHEN I.GroupId=3 THEN 'Group 3'
        WHEN I.GroupId=4 THEN 'Group 4'
    ELSE 'NoGroup'
    END AS [Group],
    I.Name AS [DBNameToSortBy],
    CONCAT('<A href="https://10.10.10.10:8124/iwc/database.iwc?db_id=',I.DatabaseInstanceID,'" target="_blank">', I.Name, '</A>')  AS [DB Instance],
    CASE
        WHEN PO.WaitTimeCategory=0 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_normal_0.png">'
        WHEN PO.WaitTimeCategory=1 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_normal_1.png">'
        WHEN PO.WaitTimeCategory=2 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_normal_2.png">'
        WHEN PO.WaitTimeCategory=3 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_normal_3.png">'
        WHEN PO.WaitTimeCategory=4 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_normal_4.png">'
        WHEN PO.WaitTimeCategory=5 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_normal_5.png">'
        WHEN PO.WaitTimeCategory=6 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_critical_1.png">'
        WHEN PO.WaitTimeCategory=7 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_critical_2.png">'
        WHEN PO.WaitTimeCategory=8 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_critical_3.png">'
        WHEN PO.WaitTimeCategory=9 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_critical_4.png">'
        WHEN PO.WaitTimeCategory=10 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_critical_5.png">'
        WHEN PO.WaitTimeCategory=11 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_warning_1.png">'
        WHEN PO.WaitTimeCategory=12 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_warning_2.png">'
        WHEN PO.WaitTimeCategory=13 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_warning_3.png">'
        WHEN PO.WaitTimeCategory=14 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_warning_4.png">'
        WHEN PO.WaitTimeCategory=15 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_warning_5.png">'
        WHEN PO.WaitTimeCategory=16 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_critical_1.png">'
        WHEN PO.WaitTimeCategory=17 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_critical_2.png">'
        WHEN PO.WaitTimeCategory=18 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_critical_3.png">'
        WHEN PO.WaitTimeCategory=19 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_critical_4.png">'
        WHEN PO.WaitTimeCategory=20 THEN '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_critical_5.png">'
        ELSE '<img src="/Orion/DPA/images/StatusIcons/WaitTimeMeter_unknown.png">'
    END AS [WaitStatus],
    CASE
        WHEN PO.CPUAlarmLevel=2 THEN '/Orion/DPA/images/StatusIcons/performance-normal.png' 
        WHEN PO.CPUAlarmLevel=3 THEN '/Orion/DPA/images/StatusIcons/performance-unknown.png' 
        WHEN PO.CPUAlarmLevel=4 THEN '/Orion/DPA/images/StatusIcons/performance-warning.png' 
        WHEN PO.CPUAlarmLevel=5 THEN '/Orion/DPA/images/StatusIcons/performance-critical.png' 
    END AS [CPU],
    CASE
        WHEN PO.MemoryAlarmLevel=2 THEN '/Orion/DPA/images/StatusIcons/performance-normal.png' 
        WHEN PO.MemoryAlarmLevel=3 THEN '/Orion/DPA/images/StatusIcons/performance-unknown.png' 
        WHEN PO.MemoryAlarmLevel=4 THEN '/Orion/DPA/images/StatusIcons/performance-warning.png' 
        WHEN PO.MemoryAlarmLevel=5 THEN '/Orion/DPA/images/StatusIcons/performance-critical.png' 
    END AS [Memory],
    CASE
        WHEN PO.DiskAlarmLevel=2 THEN '/Orion/DPA/images/StatusIcons/performance-normal.png' 
        WHEN PO.DiskAlarmLevel=3 THEN '/Orion/DPA/images/StatusIcons/performance-unknown.png' 
        WHEN PO.DiskAlarmLevel=4 THEN '/Orion/DPA/images/StatusIcons/performance-warning.png' 
        WHEN PO.DiskAlarmLevel=5 THEN '/Orion/DPA/images/StatusIcons/performance-critical.png' 
    END AS [Disk],
    CASE
        WHEN PO.SessionAlarmLevel=2 THEN '/Orion/DPA/images/StatusIcons/performance-normal.png' 
        WHEN PO.SessionAlarmLevel=3 THEN '/Orion/DPA/images/StatusIcons/performance-unknown.png' 
        WHEN PO.SessionAlarmLevel=4 THEN '/Orion/DPA/images/StatusIcons/performance-warning.png' 
        WHEN PO.SessionAlarmLevel=5 THEN '/Orion/DPA/images/StatusIcons/performance-critical.png' 
    END AS [Session]
FROM Orion.Dpa.DatabaseInstance I
INNER JOIN DPA.PerformanceOverview PO ON I.DatabaseInstanceID=PO.DatabaseId
WHERE I.IsLicensed=1

 

 

Two notes: I couldn't find DPA groupnames in Orion so you have to edit those yourself, same with url to your DPA website

 

  • Add all the columns in the datasource
  • On column "DB Instance" and "WaitStats" - check "alllow HTML tags" 
  • On column "Disk", "Memory" and "Session" - Add display setting "General Icon" and change setting to "{0}"
     
     
     
    Seashore_0-1596198666901.png

  • On column "DBNameToSortBy" - check "Hide this column...."
  • Group the result by "Group" and sort by "DBNameToSortBy"
  • Arrange the column as you like
  • Set at Title
  • You probably want to do a "Preview" and set "custom column width"

The result will be something like below

Seashore_1-1596198722263.png

  • Now we have to copy the "wait" images from DPA to Orion: (change paths to match your environment)
    • On the DPA-server, copy all PNG-filer like C:\Program Files\SolarWinds\DPA\iwc\tomcat\webapps\iwc\pages\images\WaitTimeMeter_*
    • Paste them into the Orion-web server into "C:\inetpub\SolarWinds\Orion\DPA\images\StatusIcons"

Thats is!

Hope you like it!

 

0 Kudos
1 Reply
Level 12

Updated code as I found some issues.

0 Kudos