00001 <?php 00002 // $Id: 00003 00004 /** 00005 * @file 00006 * Page multi-nagios 00007 * 00008 * Additional Doxygen documentation 00009 */ 00010 00011 /** 00012 * @page multi_nagios_help "multi-nagios" 00013 * For the use as nagios plugin. Print a message and returns with exit status 2 (Critical) 00014 * if updates available. 00015 * 00016 * multi_nagios could be run on the with -r /--root supplied Drupal installation 00017 * to check for core updates. 00018 * 00019 * or 00020 * 00021 * on a the with -l / --uri supplied site to check for core and module updates 00022 * 00023 * @note If there is a site at sites/default, this command runs on site basis, although you have only specified the Drupal installation. 00024 * 00025 * @section Aliases 00026 * @subsection multi_nagios_alias_mna mna 00027 * @subsection multi_nagios_alias_nagios nagios 00028 * @section Options 00029 * @subsection multi_nagios_file --file 00030 * Path to release information file, this could 00031 * be a (temp) file to avoid nrpe-socket timeouts. 00032 * It is also possible to supply path via URI, 00033 * like http://updates.drupal.org/release-history/drupal/6.x. 00034 * 00035 * @note This option could only be used to check the Drupal installation. 00036 * @section Examples 00037 * @subsection nagios_root Checking the Drupal installation for core updates 00038 * @code 00039 * drush -r /path/to/drupal multi-nagios 00040 * @endcode 00041 * We assume that drupal-6.14 is the recommended release. 00042 * With an older version, eg. drupal-6.13 we get: 00043 * @code 00044 * DRUPAL ROOT CRITICAL: drupal-6.13 @ /path/to/drupal 00045 * - drupal-6.14 (2009-09-16 21:40) available, see http://drupal.org/node/579476 for details. 00046 * @endcode 00047 * with exit status 2 00048 * 00049 * Or if we are running the recommended version: 00050 * @code 00051 * DRUPAL ROOT OK: drupal-6.14 @ /path/to/drupal/6.x is uptodate. 00052 * @endcode 00053 * with exit status 0. 00054 * 00055 * @code 00056 * drush -r /path/to/drupal multi-nagios --file=/path/to/file 00057 * @endcode 00058 * Same as above with a specified file. 00059 * 00060 * 00061 * @subsection nagios_site Checking a site on core and module updates 00062 * @code 00063 * drush -r /path/to/drupal -l example.com multi-nagios 00064 * @endcode 00065 * If there are no updates available, this will produce to following output: 00066 * @code 00067 * DRUPAL SITE OK - example.com @ /path/to/drupal/example.com: All modules are uptodate. 00068 * @endcode 00069 * 00070 * If there are available updates, it might produce the following output: 00071 * @code 00072 * DRUPAL SITE CRITICAL - example.com @ /path/to/drupal/sites/example.com: there are updates for admin_menu,drupal,image, see http://example.com/?q=admin/reports/updates for datails. 00073 * @endcode 00074 */
1.5.8