High on many administrators' wish lists is the ability to automate tedious tasks such as gathering information...
By submitting your email address, you agree to receive emails regarding relevant topic offers from TechTarget and its partners. You can withdraw your consent at any time. Contact TechTarget at 275 Grove Street, Newton, MA.
about an Exchange Server installation. Microsoft released three PowerShell troubleshooter scripts that can track common Exchange 2010 and SP1 issues.
Exchange administrators can configure theContent Index Troubleshooter, Database Latency Troubleshooter and Database Disk Space Troubleshooter scripts either to run periodically on a given server or as scheduled tasks or batch jobs. The scripts can also run from PowerShell.
Each troubleshooter has a MonitoringContext option to run the script continuously in the background to monitor for recurring issues and record results to a system log. If you choose not to use this option, the script runs once and generates a report to the console. To generate more information in the one-time report, add the –verbose switch.
The troubleshooting scripts offer several other options:
The Content Index troubleshooter script can alert you to Content Indexer problems and attempt to fix them. You can set the script to notify you each time an error occurs.
Exchange Search index problems can range from thread deadlock to actual corruption. You can pass a parameter to the script instructing it to attempt to resolve similar problems automatically. If your index continually develops recurring problems, this is a great way to keep things running while you locate the root cause of the problem.
Note: I recommend running this script with the repair option to fix an Indexing Stalled alert.
The Database Latency Troubleshooter has a quarantine option that you can use to block a user who is consuming an excessive amount of the mail database. In this case, excessive means that a user’s mailbox usage is consuming more than one thread for the length of time the TimeInServerThreshold option specifies over a 10-minute period.
When you turn the quarantine option on, the user will be blocked from using their mailbox for six hours. This last-ditch option should only be used if there is no other way to mitigate the load.
- The Database Disk Space Troubleshooter script also has a quarantine option that’s used to block mail access to users who are aggressively contributing to Exchange database log growth. The script will trigger an urgent alert if more than 10 users are quarantined at a given time.
Monitoring script results can also be beneficial. By default, the troubleshooting scripts run in the background and passively pull results from the system log. If you’re using a log-monitoring application like Splunk from Splunk Inc., you can set alerts to notify you when certain event IDs match IDs that scripts generated.
Note: Not every event ID needs immediate attention. For example, if you're using the Database Latency Troubleshooter, error 5710 and error 5712 are the most important. Error 5411 and error 5412 may hint at future trouble.
Whether you're using the scripts to generate informational reports on-demand or using them for long-term monitoring, there are a couple ways to harvest the results.
Take the results verbatim from the script output, pipe them into an email and send the email to yourself or another administrator. You can set up mailbox rules to raise flags if a report is sent to you or if a report contains specific words in the subject or body.
I like to use the Blat utility to accomplish this. Blat is an open-source command-line tool that you can use to send SMTP email in Windows. Blat’s script results are written out to a file in the local user’s/TEMP folder and then sent as an attachment. When you use Blat in an Exchange environment, you should use whatever internal DNS syntax you use to address Exchange such as the server-name.domain.local format.
- Use the PowerShell Community Extensions and the Send-SmtpMail cmdlet. This approach would look similar to: Send-SmtpMail -to "email@example.com" -subject "Script report" -attachment [report-filename].
ABOUT THE AUTHOR:
Serdar Yegulalp has been writing about computers and IT for more than 15 years for a variety of publications, including SearchWinIT.com, SearchExchange.com, InformationWeek and Windows magazine.