Monday, March 24, 2014

Troubleshooting Active Directory - Command Line Tools

Sponsored Links

Here are the collection of some very useful command line tools to troubleshoot Active Directory related problems.

Troubleshooting Tasks:

DC not advertising, AD object update, Bind value, KCC detecting problem with DP, trust issue, Replication, time sync, PDC latency.

Replication Health and Status:



repadmin /replsummary


repadmin /showrepl DCNAME


NLTEST Commands:

Some uses of NLTEST commands,
  • Get a list of domain controllers

  • Force a remote shutdown

  • Query the status of trust

  • Test trust relationships and the state of domain controller replication in a Windows domain

  • Force a user-account database to synchronize on Windows NT version 4.0 or earlier domain controller
Examples:


nltest /sc_query:<DomainName>

nltest /dclist:<DomainName>

nltest /sc_verify:<DomainName>

Monitor the Time Sync:



w32tm /monitor /computers:%computername%




List the Tasks:


tasklist




Name Sync issue: 


DCdiag [dcdiag /s:nameOfDC /test:NCSecDesc]




Latency with PDC issue: 



dsquery server -hasfsmo pdc




Infrastructure master latency issue:



DCDIAG /s:nameOfDC /TEST:FsmoCheck




Connection issue with GC: 


dsquery * -gc -limit 50




Advertising, timesync issue:


sc \\nameOfDC query netlogon, sc \\nameOfDC query w32time




DC not responding:


DCDIAG /s:nameOfDC /TEST:Connectivity




KCC detecting problem with DP issue:


DCDIAG /s:nameOfDC /Test:KCCEvent


Hope this post helped you. If you have any questions, please post in below comment column.

blog comments powered by Disqus
Related Posts Plugin for WordPress, Blogger...