I am trying to setup a apm template to monitor som aspects of SCCM update deployments to servers.
the one part i need help on is formatting the pending update returned values. The PS string to return the pending updates is
(Get-WmiObject -Query "SELECT * FROM CCM_SoftwareUpdate" -Namespace "ROOT\ccm\ClientSDK")
which would return this (Several of these, depending on number of pending updates)
__GENUS : 2__CLASS : CCM_SoftwareUpdate__SUPERCLASS : CCM_SoftwareBase__DYNASTY : CCM_SoftwareBase__RELPATH : CCM_SoftwareUpdate.UpdateID="Site_D0249E54-EC0C-44EA-B097-993DA68D3E4F/SUM_6ddd239d-3161- 4d68-92cc-fadef38ea6eb"__PROPERTY_COUNT : 25__DERIVATION : {CCM_SoftwareBase}__SERVER : CRN-SOL-02__NAMESPACE : ROOT\ccm\ClientSDK__PATH : \\\ROOT\ccm\ClientSDK:CCM_SoftwareUpdate.UpdateID="Site_D0249E54-EC0C-44EA-B097 -993DA68D3E4F/SUM_6ddd239d-3161-4d68-92cc-fadef38ea6eb"ArticleID : 3020338BulletinID :ComplianceState : 0ContentSize : 0Deadline : 20150215023400.000000+000Description : Install this update to resolve issues in Windows. For a complete listing of the issues that are included in this update, see the associated Microsoft Knowledge Base article for more information. After you install this item, you may have to restart your computer.ErrorCode : 0EstimatedInstallTime :EvaluationState : 0ExclusiveUpdate : FalseFullName :MaxExecutionTime : 600Name : Update for Windows Server 2012 (KB3020338)NextUserScheduledTime :NotifyUser : TrueOverrideServiceWindows : FalsePercentComplete : 0Publisher : MicrosoftRebootOutsideServiceWindows : FalseRestartDeadline :StartTime : 20150214223400.000000+000Type : 2UpdateID : Site_D0249E54-EC0C-44EA-B097-993DA68D3E4F/SUM_6ddd239d-3161-4d68-92cc-fadef38ea6ebURL : http://support.microsoft.com/kb/3020338UserUIExperience : TruePSComputerName :I would just want the Name and URL returned in the message field.
Anyone have any suggestions on how to accomplish this feat?