Script: if (!(get-module -name "ActiveDirectory") ){Add-WindowsFeature RSAT-AD-PowerShell; import-module -name "ActiveDirectory" -DisableNameChecking | out-null }$sites=(Get-ADDomainController -filter…