Below is a breakdown of a set of Open Source Management packs I’ve been working on to provide more enterprise granularity to OMS when it is connected through SCOM. The Code is posted at GitHub and I’m working to keep the issues updated and get fixes in when possible.
Check out the GitHub below, Release.zip has built packs inside:
From a 10,000ft view, when enabled, the flow of the pack is as follows:
- Overrides are placed on the Advisor and Intelligence Update Rules to prevent downloads
- A Discovery pulls a List of MPBs and MPs down, A class structure representing available and assigned packs is created.
- A Data Collection Rule pulls down the Current Version and Pack Assignment status from OMS
- The OMS MP Class Monitors and alerts on 3 items
- Version Mismatch between OMS Catalog and Installed
- Missing Pack based on OMS Catalog
- Pack that needs to be Deleted based on OMS Catalog
- The Raised Alert includes targeted tasks for the following:
- Install MP from OMS
- Download MP from OMS
- Scheduled Install Time in the Future for the OMS MP
- Remove MP from OnSite Management Group
- Once the Management Packs behind the solution come down the MP Overrides are created:
- An unsealed MP is Created at the Solution Level
- MP Includes an ‘Enable – Solution’ Group
- MP Includes a ‘Disable – Solution’ Group
- All Rules and Monitors are Disabled at the Class Level
- All Rules/Monitors are Enabled for the Context of the Enable Group
- All Rules/Monitors are Disabled with an Enforced override for the Context of the Disable Group
For further granularity in monitoring UI based rule templates have been included to create the following OMS Collection Rules:This isn’t working properly yet. WMI Perf and Events Windows Events and OCI Perf Script Events and Script Perf
The Functionality now Exists to allow a User to enable a specific solution for a sub group of computers and then disabled if for a select few (HR maybe?).
On to the Pack design and how things work under the covers.
All actual ‘Work’ and data processing is done by SCOM Rules or Tasks. A UI has been included to simplify the administration of these rules, under the covers this UI only modifies the Overrides in a Specific unsealed pack.
The Pack defines 3 Run-As Profiles. One for each of the Certificate and Proxy Credentials to Connect to OMS and one for the SDK workflows to access the management group.
For the discoveries to work properly the 4 OMS classes and the RMS Emulator class need to be added to the OMS Admin Certificate profile. There is a Task that targets the RMSEmulator and will automate this work.
There is an included reporting MP but it doesn’t offer any great functionality(yet). The back does define a new DataSet through the standard process in the XML. The DataSet does have Raw and Daily aggregations as well as configured Grooming and Deletion Stored procedures. Both Staging and Processing stored procedures are primarily shells but have error handling and all of the regular bells and whistles included.
When complete I would like to have a report produced of what the new pack does and how it differs from the current version.
To minimize the number of queries against OMS and maximize the flexibility only two queries are made, one for the Discovery and one for All other monitoring. Data from these queries flow through a dedicated windows event log that is created with the pack. It defaults to 4mb and overwrites circularly. Cookdown and some other options would work as well but this provides a quick and easy diagnosis point for errors.
– Data Processing Workflows
To simplify re-use and readability I tried to make everything code driven in PowerShell for easy reading/editing. The only exception is the UI which was compiled in .NET and included into the MPB.
Additionally in an effort of simplicity most items that do heavy work (MP Generation, MP Downloads/Installs) are event triggered Rules that monitor the custom created log. This allows flexibility in the tasks, targets, and who can call the jobs. This was initially created to overcome some hurdles with MP Resources being used on the DA.
4 Alerting workflows are available, with the 3 preferred being the State monitors for the OMS MP Class.
With the Exception of the MP Deletion Task and the Run-As Profile creation all Tasks generate events that trigger the aforementioned rules.
All Templates appear in the UI Menu and Function the same as the Built in ‘Create a Rule’ interface, with the major difference that data skips the OLTDB and SCOM DW and goes straight to OMS.
There is a Dashboard under an OMS Admin folder on the monitoring tab that shows the health and current alerts for the solutions. It also includes a connection to the OMS Interface.
The UI Below shows under OMS on the Administration Tab, once you connect to your management server it will read the Unsealed pack and populate the respective properties. I’d suggest enabling the Manual Deployment Mode and the Group Creation for testing. Things have worked great on the most recent tests.