Hi,
We would like to obtain the Overall Configuration Changes Snapshot data via the SolarWinds API.
Note we want the actual data and not to embed the SolarWinds widget in our user interface.
Please can you assist.
Regards,
Andrew
Anyone have any ideas whereabouts I would look for this information within SWQL Studio?
I asked the NCM dev team to answer this question. Hopefully you'll have an answer soon.
Much appreciated - I will await their answer.
And here's the query:
select distinct CASE WHEN CacheResults.DiffFlags = 1 THEN 'changed' WHEN CacheResults.DiffFlags = 0 THEN 'unChanged' ELSE 'unknown' END as NCMNodeStatus, NCMNodeProperties.NodeID, Nodes.NodeID as CoreNodeID, Nodes.VendorIcon, Nodes.Caption, Nodes.IPAddress, CacheResults.DiffFlags, Nodes.DetailsUrl, Nodes.Status, Nodes.ChildStatus, Nodes.Vendor, Nodes.Icon, OrionVendors.Icon, ConfigTypeFROM Cirrus.NodeProperties as NCMNodePropertiesjoin Orion.Nodes as Nodes on Nodes.NodeID=NCMNodeProperties.CoreNodeIdjoin Orion.NodesCustomProperties as OrionCustomProperties on Nodes.NodeId= OrionCustomProperties.NodeIdinner join Orion.Vendors AS OrionVendors ON Nodes.Vendor=OrionVendors.Nameleft join( select DiffFlag as DiffFlags, NodeID, ConfigType from Cirrus.LatestComparisonResults where ComparisonType=4 ) as CacheResultson NCMNodeProperties.NodeID=CacheResults.NodeID ORDER BY Nodes.Caption ASC
Similarly, we'd like to query the Last Config change time, along with the actual change. Seems like that is available via the UI and I'm hoping it's also available via API. This would be based on already knowing a particular NodeID.
Thanks!!
Val
I believe that what you're looking for can be found in Cirrus.ConfigArchive.
SELECT TOP 1000 ConfigID, NodeID, AttemptedDownloadTime, DownloadTime, ModifiedTime, Config
FROM Cirrus.ConfigArchive
ORDER BY NodeID, ModifiedTime DESC
This won't give you an analysis of exactly what the differences from the previous version are, if that's what you're looking for, but there are a number of diff tools that can perform that analysis, given the current and previous version of a file.
thanks Dan!!
What do you think about querying Cirrus.LatestComparisonResults? I see the DiffFlag in there, wondering if this can be of use. (I did a join so I can get CoreNodeID, anticipating we will already have a known Orion NodeID)
SELECT TOP 10 lc.NodeID, lc.DiffFlag, lc.ComparisonType, lc.ConfigType, n.CoreNodeID
FROM Cirrus.LatestComparisonResults lc
LEFT JOIN ncm.Nodes n ON lc.NodeID = n.NodeID
WHERE lc.ConfigType = 'Running'
Yes. I did a little digging, and it looks like the DiffFlag gets updated when a comparison is performed.