Error: Your Requested widget " wp-github-commits-6" is not in the widget list.
  • [do_widget_area sidebar-1]
    • [do_widget_area sidebar-2]
      • [do_widget id="tag_cloud-2"]
    • [do_widget_area widgets_for_shortcodes]
      • [do_widget id="wp-github-commits-14"]
      • [do_widget id="wp-github-commits-17"]
      • [do_widget id="wp-github-commits-15"]
      • [do_widget id="wp-github-commits-25"]
      • [do_widget id="wp-github-commits-3"]
      • [do_widget id="wp-github-commits-13"]
      • [do_widget id="wp-github-commits-20"]
      • [do_widget id="wp-github-commits-16"]
      • [do_widget id="wp-github-commits-2"]
      • [do_widget id="wp-github-commits-24"]
      • [do_widget id="wp-github-commits-23"]
      • [do_widget id="wp-github-commits-21"]
      • [do_widget id="wp-github-commits-5"]
      • [do_widget id="wp-github-commits-6"]
      • [do_widget id="wp-github-commits-26"]
      • [do_widget id="wp-github-commits-9"]
      • [do_widget id="wp-github-commits-22"]
      • [do_widget id="wp-github-commits-19"]
      • [do_widget id="wp-github-commits-8"]
      • [do_widget id="wp-github-commits-7"]
      • [do_widget id="wp-github-commits-18"]
      • [do_widget id="wp-github-commits-11"]
      • [do_widget id="wp-github-commits-4"]
      • [do_widget id="wp-github-commits-12"]
      • [do_widget id="wp-github-commits-27"]
    • [do_widget_area wp_inactive_widgets]
      • [do_widget id="recent-posts-2"]
      • [do_widget id="recent-comments-2"]
     

    Introduction

    I based this scipt on the MS Exchange 2010 DAG Mailbox check by Matt Haynes, but made the following changes:

    • Recovery mailbox databases are excluded. This way we don’t get any false alerts when colleagues are restoring a backup to a temporary recovery database.
    • For MS Exchange, backups are crucial, as your logs will grow very fast when they don’t get backupped. Therefore a warning is generated if the last backup date is over 26 hours and an error is generated if it was over 50 hours. (these time periods can be altered, depending on the total time your backup software requires to backup all your mailbox databases)
    • Performance data is gathered from the amount of mounted, healthy, and unhealthy mailbox databases.
    • If no mailbox databases are found on the Exchange server, an error is also generated.

    I would like to thank my colleague, De Clerck John, who created the exclusion for the recovery mailbox database and the check for last backup. His knowledge of MS Exchange and Powershell seems to be unlimited. As previously said, the script will count all healthy, failed and mounted mailbox databases and output performance data. This way, you can easily see when exactly something went wrong with your mailbox databases:

    check-ms-exchange-2010-health-graph-01

    In this screenshot it appears we had an issue on 28 April. In fact our Exchange administrators are busy migrating the mailbox databases to different MS Exchange servers, which is also clear in the next days of the graph.

    exchange

    How to monitor your MS Exchange databases?

    1. Copy the ‘check_ms_exchange_2010_health.ps1’ Powershell script to the NSClient++ scripts folder, preferably in a sub-folder ‘Powershell’ on all the Exchange 2010 servers you wish to monitor.
    2. In the nsclient.ini configuration file, define the external command like this (and restart the NSClient++ service (nscp) afterwards):
    3. Make a command in Nagios like this:
    4. Configure your service in Nagios. Use the command you previously made. Argument 1 should be the hostname of the MS Exchange server

    Grtz Willem

    Willem D'Haese
    Expert Monitoring at Digipolis
    Expert Monitoring with a demonstrated history of working in the information technology and services industry. Strong ICT skills such as monitoring, virtualization, automation.

    8 Comments

    1. OK. To start I am completely new to Nagios. I am learning.
      I have been trying to implement this for two days now.
      If I run ./check_nt -H xxx.xxx.xxx.15 -p 12489 -v CPULOAD -w 80 -c 90 -l 5,80,90,10,80,90
      I get TCP OK – 0.001 second response time on xxx.xxx.xxx.15 port 80|time=0.000751s;;;0.000000;10.000000
      If I run ./check_nrpe -H xxx.xxx.xxx.30 -p 5666 -t 60 -c check_ms_exchange_2010_health -a xxx.xxx.xxx.15
      I get CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages.

      I have been reading everything I can on NSClient and Nagios but I can not get this to work.

      1. The fact that check_nt is working, but NRPE is not seem like a config issue in NSClient. Do you have any checks that do work with NRPE? What version of NSClient++ are you using? I suggest you install 0.4.1.105. Grtz

        1. I am using the latest version 0.4.3.143×64

          I thought I had somethings working with it but not so lucky.

          I keep getting the following error in the logs
          error:D:\source\nscp\include\socket/connection.hpp:243: Failed to establish secure connection: unknown protocol: 252

          I can’t seem to find anything helpful releated to this. I also can not seem to find a decent tutorial on Nagios(on Ubuntu) and NSClient(on windows).

          1. Seems like an issue with NRPE configuration. Do you have any NRPE based checks running properly? You should be able to find a decent guid how to set this up. Check out Troy Lea’s site Box293

    2. Faced an issue when my Content index were faulty without alert.
      Changed the script (line 58) with :
      foreach($ContentIndexState in $Status){
      if(($ContentIndexState.ContentIndexState -match ‘^Healthy’) -and ($ContentIndexState.status -match ‘^Mounted’)){
      }else{
      $Content = $($ContentIndexState.name)+’ Index: ‘+$($ContentIndexState.ContentIndexState)
      $WarningList += $Content
      }
      After that all functions work well.

      Thanks

    Leave a Reply

    Your email address will not be published. Required fields are marked *

    You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">

    5 + 19 =