跳到主要內容

發表文章

目前顯示的是有「systemcenter」標籤的文章

Microsoft System Powershell

$compObject = get-wmiobject -query "select * from SMS_R_SYSTEM WHERE Name='[computername]'" -computername [sccm-server] -namespace "ROOT\SMS\site_[yoursite]" $compObject.psbase.delete() Remove-DisabledMonitoringObject Remove-SCOMDisabledClassInstance # To find out what options are available to your output of the list of objects in the group use Get-Member (GM) cmdlet Get-SCOMGroup -DisplayName "UR Computer Group" | Get-SCOMClassInstance | GM # after looking at the GM output we decide that DisplayName will work best Get-SCOMGroup -DisplayName "UR Computer Group" | Get-SCOMClassInstance | sort DisplayName |FT DisplayName For UIGeneratedMonitor: Get-SCOMMonitor | where {$_.name -eq "UIGeneratedMonitorGUID#"} | select DisplayName For UIGeneratedRule: Get-SCOMRule | where {$_.name -eq "MomUIGeneratedRuleGUID#"} | select DisplayName Create SCOM 2012 Subscribers using PowerShell Add-SCOMNotificationSubscr