Scripting SMS 2003
- From: Peter Lundin <PeterLundin@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 8 Apr 2005 07:01:03 -0700
Hi,
After installing a Secondary Site I want to verify that the role ‘Management
Point’ is enabled.
To do this I’m querying the ‘SMS_SCI_SysResUse’ class (se code below).
The query does not return information that the role is enabled, even though
I can see that it is in the SMS Admin Console, until after 1 to 20 minutes.
Is this due to intra-site replication or something like that?
Is there any other way to verify that the role has been enabled without the
delay of 1 to 20 minutes?
----------
SiteCode = "mySecSite"
CentralSiteCode = "myPriSite"
CentralSiteServer = "myPriServer"
On error resume next
Set loc = CreateObject("WbemScripting.SWbemLocator")
Set WbemServices = loc.ConnectServer( CentralSiteServer, "root\SMS\site_" &
CentralSiteCode )
Set objSiteRoles = WbemServices.ExecQuery("Select * From SMS_SCI_SysResUse
WHERE SiteCode='" & SiteCode & "'")
For Each Role In objSiteRoles
<code>
Next
----------
Regards,
Peter Lundin
.
- Follow-Ups:
- Re: Scripting SMS 2003
- From: Paul Thomsen [MSFT]
- Re: Scripting SMS 2003
- Prev by Date: RE: Upgrade SMS 2003 to SMS 2003 SP1..PLEASE HELP!!!!
- Next by Date: RE: Site code 3 character limitation
- Previous by thread: About prevent software inventory collection
- Next by thread: Re: Scripting SMS 2003
- Index(es):
Relevant Pages
|
Loading