Xsanity Sanity for Apple's Xsan and Final Cut Server.
  
Saturday, May 25 2013 @ 08:35 PM EDT
Topics
Storage (39)
People (1)
Xsan (103)
How To (26)
User Functions
Username:

Password:

Don't have an account yet? Sign up as a New User
Who's Online
Guest Users: 9
Sponsorship

Xsanity is proudly sponsored by:

Tekserve
The Old Reliable Mac Shop

How To
Free Xsan Monitoring with Nagios

We were looking for a solution to monitor the apple and other equipment of our customers. All our customers have heterogenous environments, so the Apple monitoring features were not an option. The customers wanted to have an overview over the whole equipment. We came across the open source network monitor Nagios. You can monitor almost every piece of hardware with it, either by executing check scripts on a remote machine, or query the services directly from the Nagios server via snmp.



We did the setup of the Nagios server according to this howto for Macintosh. There were no Plugins for the Apple Hardware or Xsan, so we wrote our own Plugins and published them on our website.

The plugins need a NRPE (Nagios remote program executor) daemon running on the monitored host, and also on the Nagios server. You can install the NRPE daemon, if you followed the instructions from the Nagios install howto by typing:

sudo port install nrpe

At this stage you can also install a free plugin for monitoring the Apple Xserve Raids.

sudo port install xserve-raid-tools

Unpack and put the plugins for Xsan and the Xserves into the libexec directory in /opt/local/libexec/nagios on the monitored hosts.

To get the Nagios server and monitored machine to communicate with each other you have to edit some config files on the monitored machine. Edit /opt/local/etc/nrpe/nrpe.cfg and add the following lines:

command[check_apple_xsan]=/opt/local/libexec/nagios/check_apple_xsan
command[check_apple_xserve]=/opt/local/libexec/nagios/check_apple_xserve

Then restart the NRPE daemon from the command line:

sudo /opt/local/etc/LaunchDaemons/org.macports.nrpe/nrpe.wrapper restart

You can test it from the nagios server if the plugin works:

/opt/local/libexec/nagios/check_nrpe -H HOST_ADDRESS -c check_apple_xserve

If it works you will only have to automate the checks by adding them to the config file on the Nagios server. By default the config file is /opt/local/etc/nagios/localhost.cfg. The syntax can vary very much depending on your needs and environment, so I will only post an example what a service description can look like:


define  service {
        hostgroup_name                  AppleServers
        service_description             check apple xserve
        check_command                   check_nrpe!check_apple_xserve
        max_check_attempts              4
        normal_check_interval           5
        retry_check_interval            1
        check_period                    24x7
        contact_groups                  Consol
        notification_interval           30
        notification_period             24x7
}

The check_command tells the Nagios server to use the plugin check_nrpe to execute the plugin check_apple_xserve on the hosts in the hostgroup AppleServers. It notifies the contact group Consol 24x7 if any problems occur.

Maybe that helps you to monitor you whole environment and see the problems before your users do it.



Free Xsan Monitoring with Nagios | 6 comments | Create New Account
The following comments are owned by whomever posted them.
Free Xsan Monitoring with Nagios
Authored by: goldenfri on Thursday, March 13 2008 @ 03:04 PM EDT
Nice, I'll have to try this out with my setup. Thanks!
[ Reply to This ]
Free Xsan Monitoring with Nagios
Authored by: ACSA on Friday, March 21 2008 @ 04:48 AM EDT
Thanks a lot...

We where starting to build these plugins our selfs... but this is so much nicer!!!

Arnold
[ Reply to This ]
Free Xsan Monitoring with Nagios
Authored by: Pablitus on Friday, April 18 2008 @ 03:37 PM EDT
I have an issue.... ./check_nrpe -H xxx.xxx.xxx.xxx -n Connection refused by host I followed the instructions of installing nrpe with no luck....any ideas?

---
Who has ideas is strong, but who has ideals is invincible

[ Reply to This ]
  • Free Xsan Monitoring with Nagios - Authored by: ipott on Tuesday, May 06 2008 @ 06:13 AM EDT
  • Free Xsan Monitoring with Nagios
    Authored by: donald on Friday, June 06 2008 @ 08:36 AM EDT
    I monitor xsan with nagios for some time now. I wrote some plugins too. You can find them on my website: http://www.thinkingaboutstorage.com

    There is an article about the subject too.

    Regards
    Donald

    ---
    xsan consultant

    [ Reply to This ]
    Free Xsan Monitoring with Nagios
    Authored by: Pablitus on Thursday, September 16 2010 @ 04:18 PM EDT
    Sorry to bother...but anyone has the plugins for download? consol.com webpage didn't hold anymore the plugins Thanks!

    ---
    Who has ideas is strong, but who has ideals is invincible

    [ Reply to This ]
    Story Options
    Best Viewed on a Mac | Suggested Browser: Whatever floats yer boat.