Remove a Single SCCM Policy of an Application from WMI of a machine via PowerShell
This Blog will be helpful, In case if you were in a scenario to remove a Single Policy of a SCCM created deployment from WMI of a machine.
All below Actions from PowerShell Admin Prompt
1. To verify if you have a deployment in your machine WMI via PowerShell.
Get-WmiObject -Class "CCM_Policy" -Namespace "ROOT\ccm\Policy\Machine\ActualConfig" | where
{$_.AssignmentName -like "*Google*"} | ft AssignmentName
"*Google*" -> This is an example, If you are sure about your application you are not required to use *
2. 1. To Delete If you have a deployment in your machine WMI via PowerShell.
Get-WmiObject -Class "CCM_Policy" -Namespace "ROOT\ccm\Policy\Machine\ActualConfig" | where
{$_.AssignmentName -like "*Google*"} | Remove-WmiObject
3. Finally you Start client policy retrieval
Invoke-WmiMethod -Namespace root\ccm -Class sms_client -Name TriggerSchedule "{00000000-0000-0000-0000-000000000021}"
Invoke-WmiMethod -Namespace root\ccm -Class sms_client -Name TriggerSchedule "{00000000-0000-0000-0000-000000000021}"
By Passing -Computername and $Variables in Cmdlets, You can run on machines list as you prefer
After this you will get new policies for this Application if its still deployed from sccm