0

Get SCCM site roles using Powershell

Posted by Tao Yang on 24/11/2010 in PowerShell, SCCM |

You can run the following on the site server to find out the servers holding each SCCM role:

  • $SMSProvider = get-wmiobject sms_providerlocation -namespace root\sms -filter “ProviderForLocalSite = True”
  • $SiteCode = $SMSProvider.SiteCode
  • $ProviderMachine = $SMSProvider.Machine
  • get-wmiobject -Class SMS_SystemResourceList -NameSpace root\sms\site_$SiteCode -Computername $ProviderMachine | format-list RoleName,ServerRemoteName,SiteCode

image

Tags: , ,

Want to leave a note? Just fill in the form below.

Leave a Reply

Copyright © 2010-2013 Tao Yang's System Management Blog All rights reserved.
This site is using the Desk Mess Mirrored theme, v2.2, from BuyNowShop.com.