[Pkg-nagios-changes] [SCM] UNNAMED PROJECT branch, debian/master, updated. 810edbdd3feedbfe37f4a65bee50b57b2f60fa2a
David GUENAULT
dguenault at monitoring-fr.org
Tue Feb 28 22:20:29 UTC 2012
The following commit has been merged in the debian/master branch:
commit 24ceab9024fb3e98b84e919af0834bff19a4fd38
Author: David GUENAULT <dguenault at monitoring-fr.org>
Date: Sun Feb 12 20:14:58 2012 +0100
FIX #174 check_netapp2 support
diff --git a/contrib/alternative-installation/shinken-install/shinken.conf b/contrib/alternative-installation/shinken-install/shinken.conf
index e7fecea..37bfcec 100644
--- a/contrib/alternative-installation/shinken-install/shinken.conf
+++ b/contrib/alternative-installation/shinken-install/shinken.conf
@@ -120,6 +120,10 @@ export NAGPLUGBASEURI="http://downloads.sourceforge.net/project/nagiosplug/nagio
export NAGPLUGAPTPKG="libgnutls-dev libmysqlclient-dev libssl-dev libsnmp-perl libkrb5-dev libldap2-dev libsnmp-dev libnet-snmp-perl gawk libwrap0-dev libmcrypt-dev fping snmp gettext smbclient dnsutils"
export NAGPLUGYUMPKG="gnutls-devel mysql-devel openssl-devel net-snmp-perl krb5-devel openldap-devel net-snmp-devel gawk libmcrypt-devel fping net-snmp gettext samba-client"
+export CHECKNETAPP2="http://exchange.nagios.org/components/com_mtree/attachment.php?link_id=389\&cf_id=24"
+export CHECKNETAPP2APTPKGS="snmp libnet-snmp-perl"
+export CHECKNETAPP2YUMPKGS="perl-Net-SNMP net-snmp"
+
export CHECKORACLEHEALTHAPTPKG="libdbi-perl libaio1"
export CHECKORACLEHEALTHYUMPKG="perl-DBI libaio"
export CHECKORACLEHEALTHCPAN="http://search.cpan.org/CPAN/authors/id/P/PY/PYTHIAN/DBD-Oracle-1.36.tar.gz"
diff --git a/contrib/alternative-installation/shinken-install/shinken.sh b/contrib/alternative-installation/shinken-install/shinken.sh
index ead31bb..dc6d96f 100755
--- a/contrib/alternative-installation/shinken-install/shinken.sh
+++ b/contrib/alternative-installation/shinken-install/shinken.sh
@@ -1441,8 +1441,7 @@ function install_nagios-plugins(){
tar zxvf nagios-plugins-$NAGPLUGVERS.tar.gz >> /tmp/shinken.install.log 2>&1
cd nagios-plugins-$NAGPLUGVERS
cecho " > Configure source tree" green
- echo "./configure --with-nagios-user=$SKUSER --with-nagios-group=$SKGROUP --enable-libtap --enable-extra-opts --prefix=$TARGET" >> /tmp/shinken.install.log 2>&1
- ./configure --with-nagios-user=$SKUSER --with-nagios-group=$SKGROUP --enable-libtap --enable-extra-opts --prefix=$TARGET >> /tmp/shinken.install.log 2>&1
+ ./configure --with-nagios-user=$SKUSER --with-nagios-group=$SKGROUP --enable-libtap --enable-extra-opts --prefix=$TARGET --enable-perl-modules >> /tmp/shinken.install.log 2>&1
cecho " > Building ...." green
make >> /tmp/shinken.install.log >> /tmp/shinken.install.log 2>&1
cecho " > Installing" green
@@ -1638,6 +1637,35 @@ function install_check_oracle_health(){
make install >> /tmp/shinken.install.log 2>&1
mkdir -p $TARGET/var/tmp >> /tmp/shinke.install.log 2>&1
}
+# CHECK_NETAPP2
+
+function install_check_netapp2(){
+ cadre "Install check_netapp2" green
+
+ if [ "$CODE" == "REDHAT" ]
+ then
+ cecho " > Installing prerequisites" green
+ yum -yq install $CHECKNETAPP2YUMPKGS >> /tmp/shinken.install.log
+ else
+ cecho " > Installing prerequisites" green
+ apt-get -y install $CHECKNETAPP2APTPKGS >> /tmp/shinken.install.log
+ fi
+ cd /tmp
+ cecho " > Downloading check_netapp2" green
+ wget $WGETPROXY -O check_netapp2 $CHECKNETAPP2 >> /tmp/shinken.install.log 2>&1
+ if [ $? -ne 0 ]
+ then
+ cecho " > Error while downloading check_netapp2" red
+ exit 2
+ fi
+ cecho " > Installing plugin" green
+ # fuckin assholes that upload perl scripts edited with notepad or so
+ perl -p -e 's/\r$//' < check_netapp2 > check_netapp2.pl
+ chmod +x check_netapp2.pl >> /tmp/shinken.install.log 2>&1
+ chown $SKUSER:$SKGROUP check_netapp2.pl >> /tmp/shinken.install.log 2>&1
+ cp -p check_netapp2.pl $TARGET/libexec/check_netapp2 >> /tmp/shinken.install.log 2>&1
+ sed -i "s#/usr/local/nagios/libexec#"$TARGET"/libexec#g" $TARGET/libexec/check_netapp2 >> /tmp/shinken.install.log 2>&1
+}
# CHECK_MYSQL_HEALTH
function install_check_mysql_health(){
@@ -1774,6 +1802,10 @@ while getopts "kidubcr:lz:hsvp:we:" opt; do
then
install_check_hpasm
exit 0
+ elif [ "$OPTARG" == "check_netapp2" ]
+ then
+ install_check_netapp2
+ exit 0
elif [ "$OPTARG" == "pnp4nagios" ]
then
install_pnp4nagios
--
UNNAMED PROJECT
More information about the Pkg-nagios-changes
mailing list