Use this Knowledge Script to monitor mailbox databases for the size of online maintenance window, defragmentation time, free log space, free file space, and number of mailboxes. This script raises an event if a monitored value exceeds or falls below the threshold you set. In addition, this script generates data streams for number of mailboxes in a mailbox database and number of mailboxes in a storage group.
A job executed on a database in an Exchange Server 2010, 2013, 2016, and 2019 DAG cause the job to run on all servers in the DAG. However, only the server that currently owns the database monitors that database.
NOTE:Exchange Server 2010, 2013, 2016, and 2019 do not use storage groups.
To run this Knowledge Script on clustered servers, run the AppManager agent as a domain account with Administrator privileges.
Exchange2007_Store_Group
Exchange2007_Store_Database
Exchange2007_MailboxServer
Exchange2007_Store_PFDatabase
Exchange2010_MailboxServer
Exchange2010_Store_Database
Exchange2010_Store_PFDatabase
Exchange2010_DAG_Databases
Exchange2013_MailboxServer
Exchange2013_Store_Database
Exchange2013_Store_PublicFolder
Exchange2013_DAG_Databases
Exchange2016_MailboxServer
Exchange2016_Store_Database
Exchange2016_Store_PublicFolder
Exchange2016_DAG_Databases
Exchange2019_MailboxServer
Exchange2019_Store_Database
Exchange2019_Store_PublicFolder
Exchange2019_DAG_Databases
By default, this script runs every 15 minutes.
Set the following parameters as needed:
Parameter |
How to Set It |
---|---|
General Settings |
|
Job failure event notification |
|
Event severity when job fails |
Set the severity level, from 1 to 40, to indicate the importance of an event in which the MBS_DatabaseStatus job fails. The default is 5. |
Monitor Database Defragmentation |
|
Monitor Size of Online Maintenance Window |
|
Event Notification |
|
Raise event if online maintenance window is too small or too large? |
Select Yes to raise an event if online defragmentation occurs too often or not often enough. The default is Yes. You want to ensure that defragmentation of Exchange database occurs often enough, but not too often. Microsoft recommends every 14 days. If you find that defragmentation takes less time, you can shorten your maintenance window. This script compares the values of two Performance Counters to determine whether the size of the maintenance window should be changed:
If the read-to-freed ratio is greater than 100:1, then this script raises an event indicating that the size of the maintenance window is too large and should be reduced. If the read-to-freed ratio is less than 50:1, then this script raises an event indicating that the size of the maintenance window is too small and should be increased. |
Event severity when online maintenance window is too small or too large |
Set the severity level, from 1 to 40, to indicate the importance of an event in which the maintenance window is too small or too large. The default is 15. |
Monitor Defragmentation Time |
|
Event Notification |
|
Raise event if time to defragment database exceeds threshold? |
Select Yes to raise an event if the amount of time it takes to defragment a database exceeds the threshold you set. The default is Yes. |
Threshold - Maximum database defragmentation time |
Set the maximum length of time allowed for defragmentation before an event is raised. The default is 10 hours. |
Event severity when time to defragment database exceeds threshold |
Set the severity level, from 1 to 40, to indicate the importance of an event in which the time it takes to defragment a database exceeds the threshold. The default is 15. |
Monitor Disk Space |
|
Event Notification |
|
Raise event if free space/ disk utilization for database files crosses the threshold? |
Select Yes to raise an event if the amount of disk space available for database files or disk utilization for database files crosses the threshold you set. The default is Yes. |
Set threshold for free disk space in MegaBytes |
Select Yes to set the threshold for free disk space for database files. The default is Yes. |
Threshold - Minimum free disk space for database files |
Set the minimum amount of disk space that must be available for database files to prevent an event from being raised. The default is 1024 MB. |
Event severity when free disk space for database files falls below threshold |
Set the severity level, from 1 to 40, to indicate the importance of an event in which the amount of disk space available for database files falls below the threshold. The default is 5. |
Set threshold for disk utilization in Percentage |
Select Yes to set the threshold for disk utilization for database files. The default is No. |
Threshold- Maximum disk utilization for database files |
Set the maximum percentage of disk utilization for database files that should be utilized before an event is raised. The default is 80%. |
Event severity when disk utilization for database files exceeds the threshold? |
Set the severity level, from 1 to 40, to indicate the importance of an event in which the percentage of disk utilization for database files exceeds the threshold. The default is 5. |
Raise event if free space/ disk utilization for log files crosses the threshold? |
Select Yes to raise an event if the amount of disk space available for log files or disk utilization for log files crosses the threshold you set. The default is Yes. |
Set threshold for free disk space in MegaBytes |
Select Yes to set the threshold for free disk space for log files. The default is Yes. |
Threshold - Minimum free disk space for log files |
Set the minimum amount of disk space that must be available for log files to prevent an event from being raised. The default is 1024 MB. |
Event severity when free disk space for log files falls below threshold |
Set the severity level, from 1 to 40, to indicate the importance of an event in which the amount of disk space available for log files falls below the threshold. The default is 5. |
Set threshold for disk utilization in Percentage |
Select Yes to set the threshold for disk utilization for log files. The default is No. |
Threshold- Maximum disk utilization for log files |
Set the maximum percentage of disk utilization for log files that should be utilized before an event is raised. The default is 80%. |
Event severity when disk utilization for log files exceeds the threshold |
Set the severity level, from 1 to 40, to indicate the importance of an event in which the percentage of disk utilization for log files exceeds the threshold. The default is 5. |
Monitor Mailbox Count |
|
Monitor Number of Mailboxes Per Storage Group (Exchange 2007 only) |
|
Event Notification |
|
Raise event if number of mailboxes in a storage group exceeds threshold? |
Select Yes to raise an event if the number of mailboxes in a storage group exceeds the threshold you set. The default is Yes. A storage group is a logical container only for Exchange Server 2007 databases and their associated system and transaction log files. Exchange Server 2010, 2013, 2016, and 2019 do not use storage groups. |
Threshold - Maximum number of mailboxes in a storage group |
Set the maximum number of mailboxes that can be in a storage group before an event is raised. The default is 2500 mailboxes. |
Event severity when number of mailboxes in a storage group exceeds threshold |
Set the severity level, from 1 to 40, to indicate the importance of an event in which the number of mailboxes in a storage group exceeds the threshold. The default is 15. |
Data Collection |
|
Collect data for number of mailboxes in each storage group? |
Select Yes to collect data for charts and reports. When enabled, data collection returns the number of mailboxes in a storage group during the monitoring period. The default is No. |
Monitor Number of Mailboxes Per Mailbox Database |
|
Event Notification |
|
Raise event if number of mailboxes in a mailbox database exceeds threshold? |
Select Yes to raise an event if the number of mailboxes in a database exceeds the threshold you set. The default is Yes. A database stores data, data definitions, indexes, checksums, flags, and other information associated with user mailboxes or public folders. |
Threshold - Maximum number of mailboxes in a mailbox database |
Set the maximum number of mailboxes that can be in a database before an event is raised. The default is 1000 mailboxes. |
Event severity when number of mailboxes in a mailbox database exceeds threshold |
Set the severity level, from 1 to 40, to indicate the importance of an event in which the number of mailboxes in a database exceeds the threshold. The default is 15. |
Data Collection |
|
Collect data for number of mailboxes in each mailbox database? |
Select Yes to collect data for charts and reports. When enabled, data collection returns the number of mailboxes in a database during the monitoring period. The default is No. |
Monitor Disk Activity and Usage |
|
Data Collection |
|
Collect data for percentage of elapsed time that the disk was busy servicing read and write requests? |
Select Yes to collect data for charts and reports. When enabled, data collection returns the percentage of time that was spent servicing disk reads and disk writes during the monitoring period. The default is No. |
Collect data for percentage of elapsed time that the disk was busy servicing read requests? |
Select Yes to collect data for charts and reports. When enabled, data collection returns the percentage of time that was spent servicing disk reads during the monitoring period. The default is No. |
Collect data for percentage of elapsed time that the disk was busy servicing write requests? |
Select Yes to collect data for charts and reports. When enabled, data collection returns the percentage of time that was spent servicing disk writes during the monitoring period. The default is No. |
Collect data for average number of both read and write requests that were queued for the disk during the sample interval? |
Select Yes to collect data for charts and reports. When enabled, data collection returns the number of read and write requests queued for servicing during the monitoring period. The default is No. |