![]() My advice is to use a distribution group, so that any time you need to modify the list of recipients you can simply change the distribution group membership instead of needing to modify the script code. SmtpServer = ""Ī lot of people ask how to add multiple recipients to the SMTP settings. $smtpsettings = "Exchange Server Health Report - $now" If you use the report mode you’ll get a HTML file containing the health check results, and/or an email to your designated address if you also use the send email option.įor the email functionality to work please update these variables in the script to suit your environment. \Test-ExchangeServerHealth.ps1Ĭhecks all servers in the organization and outputs the results to the shell window.\Test-ExchangeServerHealth.ps1 -Server HO-EX2010-MB1Ĭhecks the server HO-EX2010-MB1 and outputs the results to the shell window.\Test-ExchangeServerHealth.ps1 -ReportMode -SendEmailĬhecks all servers in the organization, outputs the results to the shell window, a HTML report, and emails the HTML report to the address configured in the script. -Log, Writes a log file to help with troubleshooting.Įxamples.-AlertsOnly, Only sends the email report if at least one error or warning was detected.-SendEmail, Sends the HTML report via email using the SMTP configuration within the script.-ReportFile, Allows you to specify a different HTML report file name than the default. ![]() A default file name is used if none is specified. -ReportMode, Set to $true to generate a HTML report.-Server, Perform a health check of a single server. ![]() ![]() If you find a bug please consider raising it as an issue on Github. This script is available to download from the TechNet Script Gallery or Github. This is a useful script to run as a daily health check first thing in the morning to identify any problems that may have occurred overnight, and give you a chance to fix them before your end users notice. The report includes a summary of issues that were found, as well as a color-coded table with the detailed test results to help you quickly spot problems. This PowerShell script will perform a health check of your Exchange Server environment, including servers and database availability groups, and output a HTML report that you can send to your inbox. ![]()
0 Comments
Leave a Reply. |