Test-ServiceHealth
How to test the health of Exchange Server services health quickly? Applies to: Exchange Server 2010 SP2
I have found a useful cmdlet Test-ServiceHealth to test whether all the Microsoft Windows services that Exchange requires on a server have started.
Simply run Test-ServiceHealth and you will get the output like as below when every services are running at a good condition:
RequiredServicesRunning: True indicates a good health
Let’s assume there are some issues to the services. Then you may see the result as shown below:
RequiredServicesRunning: False indicates the services which are not in good health
Then, we can use the PowerShell capabilities to fix all the issues by starting all the stopped services
Test-ServiceHealth | Select ServicesNotRunning | foreach { Start-Service $_.ServicesNotRunning }
Test-ServiceHealth again after some time to check the health again