$DCs = Get-ADDomainController -Filter * | Select-Object name -ExpandProperty Name
foreach ($dc in $dcs){
Invoke-Command -ComputerName $dc -ScriptBlock {Get-ItemProperty -Path HKLM:\System\CurrentControlSet\Services\ntds\Diagnostics\ | select @{Name="Server Name";e={$dc}},"16 LDAP Interface Events"}
}
No comments:
Post a Comment