1 of 1 people found this helpful
There is no where in the database that this definition is stored as normalised data and therefore this is going to require something creative.
We have created something reasonably similar for a customer previously and identified two methods:
1. Create a Compliance Policy, where you create a rule for each condition you require. Use config block to search within Interfaces. Within the Cirrus.PolicyCacheResults SWQL entity you will see a column 'XMLResults'. You could use this to identify the results and perform some counts using some lovely SWQL code
2. (This is the route we took a few years ago). Created a custom SQL Function, which are called via Stored Procedure that looks within the NCM_ConfigArchive > Config table and cell. The Function parses through the config.
This is pretty heavy lifting stuff, but the data does exist within NCM, just not in a nice format.
Installation | Consultancy | Training | Licenses
Mark, yours is the method I thought I'd probably end up using, but I was hoping there was something someone was already using to provide a simple and fast useful output. I"ll build a Compliance Report that searches for the required config lines and try to figure out a pretty way to count the switches and switchports.
But I'd be open for any suggestions or examples of SQL or SWQL that could ouput the total count of ports / switches that comply or do NOT comply.
I had done something similar a while back too, only mine was probably far less formal than what you need.
These are from the land before time, but they sounded similar to what you were asking for... at least they sound similar to each other in my head.
Basically, I just made compliance reports for each thing I needed to find, then made a job to run on SQL server to count them all out. Probably also similar to option 2 from m_roberts, but maybe not as advanced as what they did.
Let us know how you did it... once you do it.