How to Use Get-HealthReport Command in Exchange Server?

It is important to regularly monitor the health of Exchange Server and its various services. This helps detect issues that may have serious repercussions if left unattended. To check the health status of the services and processes, Exchange Server offers a PowerShell command, named Get-HealthReport.

This command gives output of the specified server, the status, the set or process name, alert value of the process, and the monitor count. You can also script the command to automate the process. This will help you to immediately identify if a critical process is either offline or unhealthy. This is ideal to output the data in either API or monitoring system to get alerts via email or SMS to tackle the issue immediately. Below, we will see how to use the Get-HealthReport PowerShell command in Exchange Server.

Process to Use Get-HealthReport Command in Exchange Server

Before running the Get-HealthReport command, you need some basic permissions. To get the permissions and roles needed, run the following command.

Get-ManagementRole -Cmdlet Add-MailboxDatabaseCopy

As you can see (in the above image), the following roles are needed.

  • View-Only Configuration
  • O365SupportViewConfig
To get the permissions needed for the role, you can run the following command.
$Permissions = Get-ManagementRole -Cmdlet Add-MailboxDatabaseCopy
$Permissions | foreach {Get-ManagementRoleAssignment -Role $_.Name -Delegating $false | Format-Table -Auto Role,RoleAssigneeType,RoleAssigneeName}

From the output of this command (see the above image), you need to assign the role of Organization Management and the Server Management. You can assign these roles via PowerShell in the Exchange Management Shell (EMS) or the Exchange Admin Center (EAC).

After assigning the required roles and permissions, you can run the command (as given below) by specifying the Identity (the server name) of the Exchange Server.

Get-HealthReport -Identity

The above command will return all the information on the specified Exchange Server.

If you don’t want the output of all the components of the Exchange Server, you can run the command with the FL parameter (see the below example).

Get-HealthReport -Identity | FL

This will load all the information. You can see the HealthSet parameter, which is the grouping of each component.

If you want to only show the OWA.Protocol.Dep, you can run the command as given below.

Get-HealthReport -Identity -HealthSet

To get the information of the services which would directly impact the high availability of the Exchange Server in a Database Availability Group (DAG), you can use the HAImpactingOnly parameter (see the below example).

Get-HealthReport -Identity -HaImpactingOnly

Conclusion

Above, we have discussed how to use the Get-HealthReport PowerShell command in Exchange Server. You can monitor various services and processes using this command. You can also use monitoring scripts to ensure that all processes are running successfully. You can also customize the Get-HealthReport command to get the health of specific services and processes.

If the server crashes or services are interrupted, then this can lead to database corruption. In such a case, you can use the native tools of Exchange Server, such as the ESEUtil. But there is no guarantee that the data will be recovered. Alternatively, you can take the help of exchange repair tool, such as Stellar Repair for Exchange. This will help in getting the server and data up and running with less effort and in less time. The application can easily open corrupted EDB file from any version of Exchange Server and with no size limit. It allows to granularly export the EDB data to PST and other file formats. It can also export data from the EDB file directly to a live Exchange Server database or Office 365. It can export all the EDB file items, including user mailboxes, user archives, shared mailboxes, disabled mailboxes, and even public folders.



Was this article helpful?
About The Author
author image
Shelly Bhardwaj linkdin Icon

Shelly is technology expert and core knowledge of Exchange Server, Outlook.

Table of Contents

WHY STELLAR® IS GLOBAL LEADER

Why Choose Stellar?
  • 0M+

    Customers

  • 0+

    Years of Excellence

  • 0+

    R&D Engineers

  • 0+

    Countries

  • 0+

    PARTNERS

  • 0+

    Awards Received