Loading |
VBScript |
JavaScript |
Powershell |
Search Options: Enable a Global Catalog ServerContent of Enable a Global Catalog Server.vbsMD5 Hash: 576A79714EF41B832E07170CF314D134 |
||
' Description: Enables the global catalog service on the domain controller atl-dc-01.
strComputer = "atl-dc-01" Const NTDSDSA_OPT_IS_GC = 1 Set objRootDSE = GetObject("LDAP://" & strComputer & "/RootDSE") strDsServiceDN = objRootDSE.Get("dsServiceName") Set objDsRoot = GetObject _ ("LDAP://" & strComputer & "/" & strDsServiceDN) intOptions = objDsRoot.Get("options") If (intOptions And NTDSDSA_OPT_IS_GC) = FALSE Then objDsRoot.Put "options" , intOptions Or NTDSDSA_OPT_IS_GC objDsRoot.Setinfo End If | ||
© 2008 - 2013 Boris Toll :: Scripts available: 6.481 :: :: scriptbox.toll.at :: :: powered by www.toll.at :: |