In this article, I’ll show you how to monitor an Exchange Server 2016 DAG using Exchange PowerShell.
Monitoring your Exchange DAG Is one of the most important tasks you should know about and have a script or something that will run at least once a day and alert you If Everything Is working as planned.
I’ve seen so many great admins that had an Exchange Server outage simply because they didn’t monitor their DAG.
Note: You can visit the following article How to Create Exchange Server 2016 DAG I have done about settings up Exchange Server 2016 DAG.
To get started, below you will see the most Important cmdlet for DAG monitoring:
When looking at the output make sure the CopyQueue numbers are not too high and not Increasing.
Make sure the Content Index State Is always healthy if it’s not you have to fix it ASAP
As said above the most important thing you would like to check Is the ContentIndexState which you will see on the right side
Make sure It’s In a Healthy state
To monitor a specific Database Copy Status run the cmdlet below
Get-MailboxDatabaseCopyStatus -db DB01
The next check will test the Replication Health of the Server and will tell you If Something Is not working
Test-ReplicationHealth -Server ex2016s2
To monitor the message queue across the DAG, I’m using the cmdlet below:
Get-QueueDigest -dag DAG01