Nagios checks for drupal and wordpress versions

I wrote two simple checks scripts for nagios which can be used to monitor drupal and wordpress installations for updates. Both scripts use functions of the integrated update mechanisms of drupal or wordpress to check for updates.

Both scripts take the path to a installation as argument:

# ./check_drupal_update.php <path_to_drupal>
OK - all modules current
# ./check_wp_versions.php <path_to_wp>
OK - core ok ; plugins ok

An example nagios configuration:

define command{
command_name    check_wp_versions
command_line    /usr/local/bin/check_wp_versions.php $ARG1$
}
define service {
use                             generic-service
host_name                       host.zumsel.de
service_description             www.zumsel.de-wp-versions
check_command                   check_wp_versions!/var/www/www.zumsel.de/htdocs/blog/
max_check_attempts              1
normal_check_interval           720
contact_groups                  zumsel_admin
}

Download:
check_drupal_update.php.gz
check_wp_versions.php.gz

Ein Gedanke zu “Nagios checks for drupal and wordpress versions

Hinterlasse eine Antwort

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind markiert *

*

Du kannst folgende HTML-Tags benutzen: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>