Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 491008 - =net-analyzer/nagios-plugins-1.5 version bump
Summary: =net-analyzer/nagios-plugins-1.5 version bump
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Sysadmin Bugs
URL: https://www.nagios-plugins.org/news/r...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-11-11 09:43 UTC by Tomáš Mózes
Modified: 2014-11-22 21:46 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tomáš Mózes 2013-11-11 09:43:24 UTC
https://www.nagios-plugins.org/news/release-1-5.html

Enhancements
    New check_dbi plugin for checking an (SQL) database using DBI
    Let OpenSSL load its configuration file (see the OPENSSL_config(3) man page)
    Add performance data to check_apt
    Add performance data to check_procs
    Added -4/-6 options to check_dig
    New check_oracle --connect option to perform real login
    New check_nagios -t option to override the default timeout
    New check_disk -f/--freespace-ignore-reserved option to ignore space reserved for root
    New check_disk -N/--include-type option to limit the filesystem types to check
    Allow for building the plugins in parallel
    Add --without-{dbi,ldap,radius} options to ./configure
    Made Verbose output of check_sensors compliant
    New switch -E/--extended-perfdata for check_http to print additional performance data
    New check_http -d option to specify a string to expect within the response headers
    New check_http -J/-K options for client certificate authentication support
    Add support for executing queries to check_pgsql
    Let check_pgsql accept a UNIX socket directory as hostname
    New check_pgsql -o option to specify additional connection parameters
    New check_fping -S option to specify the source IP address
    New check_fping -I option to specify the interface to bind to
    Let check_fping support IPv6
    New check_procs -k option to ignore kernel threads (on Linux)
    Let check_procs use /proc/<PID>/exe (if available) instead of getpid(2), unless -T is specified
    Let check_mysql support SSL
    Let check_mysql add perfromance metrics for all checks
    New check_mysql -f option to specify a client options file
    New check_mysql -g option to specify a client options group
    New check_snmp --offset option to allow for adding/substracting an offset value to sensor data
    Let check_snmp support an arbitrary number of OIDs
    Let check_ide_smart support NetBSD

Fixes
    Change the MAIL FROM command generated by check_smtp to be RFC compliant
    Fix compilation of check_http without SSL support
    Fix check_snmp reversed threshold ranges (backward-compatibility)
    Fix check_snmp memory violation when using more than 8 OIDs
    Fix check_apt security regular expression
    Fix check_http handling extra header (-k) containing semicolons
    Fix check_apt handling unknown exit codes from apt-get
    Fix deprecated imports of check_nmap.py

Warnings
    check_http behaviour of -k/--header changed since it does not separate multiple headers by semicolons anymore. Use multiple -k switches instead.
    check_http's --proxy_authorization option is now called --proxy-authorization (it was always documented this way)
    The contrib directory has been removed. These days, sites such as Nagios Exchange and Monitoring Exchange serve as much better places for publishing plugins not maintained by the Nagios Plugins Development Team.
Comment 1 Tomáš Mózes 2013-11-11 09:56:08 UTC
Sorry, this should be version 1.5, not 1.5.0.
Comment 2 Jon Gerdes 2014-01-19 16:00:00 UTC
There has recently been a (rather contraversial) fork of the Nagios-Plugins project. 

This: https://bugzilla.redhat.com/show_bug.cgi?id=1054340 goes into some detail and includes views from most sides of the argument.

One solution might be a virtual package for monitoring-plugins for Nagios and Icinga (and any others) that is satisfied by either upstream.

My personal preference would be for a rename and new source URL from monitoring-plugins.

Cheers
Jon
Comment 3 Alexandr Tiurin 2014-03-25 08:05:30 UTC
nagios-plugins-2-0 released

https://nagios-plugins.org/nagios-plugins-2-0-released/
Comment 4 Tomáš Mózes 2014-04-24 13:49:36 UTC
@Jon
a virtual package would be great, for release 1.5 I would use the name nagios-plugins, since the name in the distro package is still nagios-plugins. For the next release, it should be renamed for sure.

@Alexandr
version 2.0 you mention should belong somewhere else, because it was done by the new nagios-plugins developers

Below is an ebuild for 1.5. Nls doesn't work, because after configure, po/Makefile contains:
mkdir_p = $(MKDIR_P)

But it should contain:
mkdir_p = /bin/mkdir -p

It's not an upstream stuff, because a ./configure and make on the source gives the correct output.

For gnutls there is a patch, since they introduced code which isn't supported in gnutls:
https://github.com/monitoring-plugins/monitoring-plugins/issues/1254


--- /usr/portage/net-analyzer/nagios-plugins/nagios-plugins-1.4.16-r3.ebuild    2012-11-21 20:01:22.000000000 +0100
+++ nagios-plugins-1.5.ebuild   2014-04-24 15:24:25.490311951 +0200
@@ -8,42 +8,42 @@
 
 inherit autotools eutils multilib user
 
-DESCRIPTION="Nagios $PV plugins - Pack of plugins to make Nagios work properly"
-HOMEPAGE="http://www.nagios.org/"
-SRC_URI="mirror://sourceforge/nagiosplug/${P}.tar.gz
-       http://dev.gentoo.org/~flameeyes/${PN}/${P}-patches-${PATCHSET}.tar.xz"
+DESCRIPTION="Monitoring plugins - Pack of plugins to make Icinga, Naemon, Nagios, Shinken, Sensu work properly"
+HOMEPAGE="http://www.monitoring-plugins.org"
+SRC_URI="https://www.monitoring-plugins.org/download/${P}.tar.gz
+       http://dev.gentoo.org/~flameeyes/${PN}/${PN}-1.4.16-patches-${PATCHSET}.tar.xz"
 
 LICENSE="GPL-2"
 SLOT="0"
 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ppc ~ppc64 ~sparc ~x86"
 IUSE="+ssl samba mysql postgres ldap snmp nagios-dns nagios-ntp nagios-ping nagios-ssh nagios-game ups ipv6 radius +suid jabber gnutls sudo smart"
 
-DEPEND="ldap? ( >=net-nds/openldap-2.0.25 )
+DEPEND="ldap? ( net-nds/openldap )
        mysql? ( virtual/mysql )
        postgres? ( dev-db/postgresql-base )
        ssl? (
-               !gnutls? ( >=dev-libs/openssl-0.9.6g )
+               !gnutls? ( dev-libs/openssl )
                gnutls? ( net-libs/gnutls )
        )
-       radius? ( >=net-dialup/radiusclient-0.3.2 )"
+       radius? ( net-dialup/radiusclient )"
 
 # tests try to ssh into the box itself
 RESTRICT="test"
 
 RDEPEND="${DEPEND}
-       >=dev-lang/perl-5.6.1-r7
-       samba? ( >=net-fs/samba-2.2.5-r1 )
-       snmp? ( >=dev-perl/Net-SNMP-4.0.1-r1 )
+       dev-lang/perl
+       samba? ( net-fs/samba )
+       snmp? ( dev-perl/Net-SNMP )
        mysql? ( dev-perl/DBI
                         dev-perl/DBD-mysql )
-       nagios-dns? ( >=net-dns/bind-tools-9.2.2_rc1 )
-       nagios-ntp? ( >=net-misc/ntp-4.1.1a )
-       nagios-ping? ( >=net-analyzer/fping-2.4_beta2-r1 )
-       nagios-ssh? ( >=net-misc/openssh-3.5_p1 )
-       ups? ( >=sys-power/nut-1.4 )
-       nagios-game? ( >=games-util/qstat-2.6 )
-       jabber? ( >=dev-perl/Net-Jabber-2.0 )
-       sudo? ( >=app-admin/sudo-1.8.5 )
+       nagios-dns? ( net-dns/bind-tools )
+       nagios-ntp? ( net-misc/ntp )
+       nagios-ping? ( net-analyzer/fping )
+       nagios-ssh? ( net-misc/openssh )
+       ups? ( sys-power/nut )
+       nagios-game? ( games-util/qstat )
+       jabber? ( dev-perl/Net-Jabber )
+       sudo? ( app-admin/sudo )
        smart? ( sys-apps/smartmontools )"

 REQUIRED_USE="smart? ( sudo )"
@@ -54,7 +54,12 @@
 }
 
 src_prepare() {
-       epatch "${WORKDIR}"/patches/*.patch
+       if use gnutls; then
+         epatch "${FILESDIR}"/gnutls_compatibility.patch
+       fi
+       
+       epatch "${WORKDIR}"/patches/0003-configure-use-pg_config-to-find-where-to-find-Postgr.patch
+       epatch "${WORKDIR}"/patches/0004-configure-don-t-expect-presence-of-127.0.0.1.patch
 
        eautoreconf
 }
@@ -76,11 +81,12 @@
                $(use_with radius) \
                $(use_with postgres pgsql /usr) \
                ${myconf} \
+               --disable-nls \
                --libexecdir=/usr/$(get_libdir)/nagios/plugins \
                --sysconfdir=/etc/nagios
 }
 
-DOCS=( ACKNOWLEDGEMENTS AUTHORS BUGS CODING ChangeLog FAQ NEWS README REQUIREMENTS SUPPORT THANKS )
+DOCS=( ACKNOWLEDGEMENTS AUTHORS CODING ChangeLog FAQ LEGAL NEWS README REQUIREMENTS SUPPORT THANKS )
 
 src_install() {
        default
@@ -101,26 +107,6 @@
                doins "${T}"/50${PN}
        fi
 
-       cd contrib/
-       dodoc *README*
-
-       # remove stuff that is way too broken to fix, or for which the USE
-       # flag has been removed.
-       rm -r tarballs aix \
-               check_compaq_insight.pl *.c *README* \
-               $(usex !jabber nagios_sendim.pl) \
-               $(usex !smart check_smart.pl)
-
-       # fix perl interpreter
-       sed -i -e '1s:/usr/local/bin/perl:/usr/bin/perl:' \
-               "${S}"/contrib/* || die
-
-       exeinto ${nagiosplugindir}/contrib
-       doexe *
-
-       dosym ../utils.sh ${nagiosplugindir}/contrib/utils.sh
-       dosym ../utils.pm ${nagiosplugindir}/contrib/utils.pm
-
        # enforce permissions/owners (seem to trigger only in some case)
        chown -R root:nagios "${D}${nagiosplugindir}" || die
        chmod -R o-rwx "${D}${nagiosplugindir}" || die
@@ -132,5 +118,4 @@
        elog "This ebuild has a number of USE flags which determines what nagios is able to monitor."
        elog "Depending on what you want to monitor with nagios, some or all of these USE"
        elog "flags need to be set for nagios to function correctly."
-       elog "contrib plugins are installed into /usr/$(get_libdir)/nagios/plugins/contrib"
 }



gnutls_compatibility.patch
--- plugins/sslutils.c.orig	2014-04-24 08:41:35.837157526 +0200
+++ plugins/sslutils.c	2014-04-24 08:42:02.677234072 +0200
@@ -86,10 +86,10 @@
 	if (cert && privkey) {
 		SSL_CTX_use_certificate_file(c, cert, SSL_FILETYPE_PEM);
 		SSL_CTX_use_PrivateKey_file(c, privkey, SSL_FILETYPE_PEM);
-		if (!SSL_CTX_check_private_key(c)) {
+		/*if (!SSL_CTX_check_private_key(c)) {
 			printf ("%s\n", _("CRITICAL - Private key does not seem to match certificate!\n"));
 			return STATE_CRITICAL;
-		}
+		}*/
 	}
 #ifdef SSL_OP_NO_TICKET
 	SSL_CTX_set_options(c, SSL_OP_NO_TICKET);
Comment 5 Tomáš Mózes 2014-05-21 16:19:14 UTC
We have deployed v1.5 on about 50 servers, so far so good (amd64).
Comment 6 Michael Orlitzky gentoo-dev 2014-11-22 21:46:21 UTC
Marking obsolete, since we have v2.0.3 in the tree now.