Hi Microsoft community,
Is there a PowerShell one-liner or an MMC snapin I can use to easily locate which DCs in my Forest are read only DCs?
I didn't install this Active Directory, I inherited it. :)
Thank you!
Technology Tips and News
Hi Microsoft community,
Is there a PowerShell one-liner or an MMC snapin I can use to easily locate which DCs in my Forest are read only DCs?
I didn't install this Active Directory, I inherited it. :)
Thank you!
Get All Domain Controllers in the default Domain.
import-module ActiveDirectory
$ADInfo = Get-ADDomain
$ADDomainReadOnlyReplicaDirectoryServers = $ADInfo.ReadOnlyReplicaDirectoryServers
$ADDomainReplicaDirectoryServers = $ADInfo.ReplicaDirectoryServers
$DomainControllers = $ADDomainReadOnlyReplicaDirectoryServers + ` $ADDomainReplicaDirectoryServers
OR
import-module ActiveDirectory
$DomainControllers = Get-ADDomainController -filter * -DomainName $DOMAIN