Domain Controller Health Check Commands
You should see the tests result in the following screen.
Domain controller health check commands. If you want to see a list of all of command switches you can add to dcdiag when you run it you can use the h switch when running dcdiag. One of the oldest and most useful tools to figure out what s going on in your active directory environment is dcdiag. Provided you are running command prompt or powershell on a domain controller or a system running rsat you can access the tool by running.
Using a to run against all domain controllers. None dsa object. If you have many domain controllers this will be a lot of information displayed this is where using the f option would come in handy.
Running dcdiag tests with a powershell boost dcdiag or domain controller diagnostics is the microsoft approved way of validating active directory services. Function get dchealth cmdletbinding parameters used in this function param parameter position 0 mandatory true helpmessage provide server name valuefrompipeline true server parameter position 1 mandatory true helpmessage select dc health check dcdiag repadmin valuefrompipeline true validateset dcdiag repadmin string check checking if server exist try dc get addomaincontroller identity server catch write host error. Use dcdiag with powershell to check domain controller health.
I get asked over and over about what i do when i m performing a health check on a domain controller. C windows system32 repadmin showrepl dc2 default first site name dc2 dsa options. Now we have an image of the health status of domain controller in my enviroment quick and simple.
In addition to checking the health of your domain controllers. If you want to see the replication status for a specific domain controller use this command. Below you will see some of the commands that i use when i need to ensure my domain controllers are still healthy after some sort of change like patching.
All we know that the best practise is to have 2 domain controllers and replicate between them. The tests give you a high level overview of the overall health of your domain between your domain controllers. If you re unsure check out this article for testing rpc ports with powershell and use the test wsman powershell command to test wsman remote capabilities.