Update: Version 2 – https://techwizard.cloud/2021/05/04/active-directory-health-check-v2/
As Technet Gallery is retiring so moving the code to Git Hub. (click below github download link for this script)
Updated with few more Tests: FSMOCheck & Advertising
Note:- will not work on Non-English Platforms.
Hi Readers,
Sharing a script that can be used for checking AD Health, This script is similar to one of my other health Check scripts that we use for exchange
This will check below:
Ping,Netlogon,NTDS,DNS,DCdiag Test(Replication,sysvol,Services)
Just download the zip file from above & run the batch file using Admin privileges.(run it from machine that is not DC)
Below is the report that will arrive in your mailbox.
Change Variables in .ps1 as needed:
$smtphost = “SMTP.labtest.com”
$from = “DoNotReply@labtest.com”
$to = “Sukhija@labtest.com”
$timeout = “60”
Please rate the script if it worked for you 🙂
Pre-requisites/Assumptions: Supports tools are installed (as DCDiag is used), Access to ActiveDirectory (Assumption is AD admin will be using this script), Powershell.
If you face any issues with this script functioning, pls use comments.
Thanks for reading …
Tech Wizard
Pingback: Active Directory Health Check V2 | Tech Wizard
I’m getting this error MSG while running power shell.
xception calling “Send” with “1” argument(s): “Failure sending mail.”
At C:\ADHealthCheckV2\ADHealthCheck\ADHealthCheck.ps1:350 char:1
+ $smtp.send($msg)
+ ~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : SmtpException
That is SMTP server error your smtp server might have restrictions..
report in html might already have been generated and is in the same folder.
Great tool! We’ve been using it for years on dozens of AD forests we manage. We recently introduced Server 2022 DC’s to a couple forests and started getting Yellow warnings on NetlogonService and DNSServiceStatus results. The pattern is running the script on a non-’22 server errors on results for the ’22 server, and running it on the ’22 server errors on the non-’22 servers but is fine for itself. Any idea what Microsoft changed in Server ’22 to introduce this behavior? Thanks!
Changing the timeout from 60 to 120 fixed it where there are 2022 DC’s in the forest.