![Active Directory Administration Cookbook](https://wfqqreader-1252317822.image.myqcloud.com/cover/629/36698629/b_36698629.jpg)
上QQ阅读APP看书,第一时间看更新
Using the Active Directory module for Windows PowerShell to inventory domain controllers
Using the Active Directory Module for Windows PowerShell to inventory domain controllers is even easier.
Simply use the following PowerShell script:
Import-Module ActiveDirectory
Get-ADDomainController | Select Name
If you want more information on the domain controllers within the current domain, simply add the characteristics you would like to see after the Select statement. For instance, you can add IPv4Address, IsGlobalCatalog, isReadOnly, OperatingSystem and Site for good measure. If you're looking for a smart layout simply append | Format-Table. If you want to get the information straight to your clipboard so you can paste it in a report or anywhere else, append | clip.