Monitoring Microsoft Exchange 2003 Servers using Nagios
Thru the time I have developed a few usefull plugins to better monitor exchange servers.
I hope system administrator around the world can benefit from it. It has only being tested under exchange 2003. Any comments, improvements are welcome.
Here are a list of these plugins:
* Exchange_BD – Gets the phsycal size of the Exchange database files, looks into the files .edb and .stm (must pass arguments where files are)
Posible improvements: Dynamic finds the location of the files, querying via LDAP. Display total size by adding all files.
* Exchange_Top_MBOX – Get the top X mailox sizes, allows threasholds if any mailbox is bigger then X megabytes go to warning or critical.
* Exchange_Top_Emails – Most complicated script, gets the total number of emails sent the day before, and prints out the top X “spammers”, allows threasholds.
* Exchange_Backups – Checks when was the last time exchange server was correctly backuped and logs where flushed, I find it a very usefull plugin. Allows threasholds, ex. if backup was not done in last 4 days call warning if no backup during last 10 days raize critical alarm.
* Exchange_Logins – How many users are currently login into the server. (not originaly mine) Uses WMI query, comes with standard NRPE_NT plugins v2.
* Exchange_MailBoxes – Gets the total number of mailboxes in the exchange server, works even with multiple Storage Groups.
Important Note: All these scripts requires Nagios + NRPE_NT (nagios agent) installed on servers. You will also need to define the plugins in nrpe.cfg here is how I have it:
command[get_total_mbox]=cscript.exe //nologo //T:90 c:nrpe_ntpluginsv2check_mboxtotal.vbs
command[get_top_mbox]=cscript.exe //nologo //T:90 c:nrpe_ntpluginsv2check_mboxsize.wsf -h $ARG1$ -t $ARG2$ -w $ARG3$ -c $ARG4$
command[get_top_emailers]=cscript.exe //nologo //T:90 c:nrpe_ntpluginsv2check_emailers.wsf “$ARG1$” “$ARG2$” “$ARG3$”
command[get_exchange_mbox_logons]=cscript.exe //nologo //T:60 c:nrpe_ntpluginsv2check_counter_rawcount.vbs -h “127.0.0.1” -class “Win32_PerfRawData_MSExchangeIS_MSExchangeISMailbox” -inst “Name=_Total” -prop “ActiveClientLogons” -w “$ARG1$” -c “$ARG2$”
command[check_filesize]=cscript.exe //nologo //T:60 c:nrpe_ntpluginsv2check_filesize.vbs -p “$ARG1$” -f “$ARG2$” -w “$ARG3$” -c “$ARG4$”
command[check_backup]=cscript.exe //nologo //T:60 c:nrpe_ntpluginsv2check_backup.vbs -w “$ARG1$” -c “$ARG2$”
There are many more interesting plugins when monitoring Microsoft Exchange servers:
Check Windows Update
Check Exchange Counters (performance)
Check Active Directory
Check POP3 Account
Check Black Lists
Check BlackBerry Server State
Check Exchange Webmail OWA (very nice)
Check Exchange – multiple options
Please help me maintain this site with a simple click: