Script ruoli FSMO e GlobalCatalogs

Script Powershell per individuare i ruoli FSMO ed i server GC

#Importazione module AD se non presente
if(!(get-module activedirectory)) {Import-Module activedirectory -Cmdlet Get-ADForest, Get-ADDomain }

#Recupero nome dominio e foresta
$DomainName = Get-ADDomain
$ForestName = Get-ADForest
Function FSMO_GL {
$obj = New-Object PSObject -Property @{
Server_PDC = $DomainName.PDCEmulator
Server_RID = $DomainName.RIDMaster
Server_Infrastructure = $DomainName.InfrastructureMaster
Server_Schema = $ForestName.SchemaMaster
Server_DomainNaming = $ForestName.DomainNamingMaster
Server_GlobalCatalogs = $ForestName.GlobalCatalogs
}
$obj

}
FSMO_GL

DISCLAIMER: Nessuna garanzia per lo script. Lo usate a vostro rischio. Lo scrivente non è responsabile di qualunque danno possa eventualmente derivarne 😉

Liked this post? Follow this blog to get more. 

Rispondi

Questo sito usa Akismet per ridurre lo spam. Scopri come i tuoi dati vengono elaborati.