drop olds
This commit is contained in:
parent
f9a50c79f4
commit
913f6869c9
|
@ -1,4 +0,0 @@
|
|||
AUX define-own-mysql-port-constant.patch 3296 BLAKE2B 7a7c88c6f2c71bc1fc2f802ad202c2d2dbf3ede5af55dbe46cc15a064d37178b27670e30aa7bea07147456ce4d3e1ce9f495fa6df9deb4095367a7427e217719 SHA512 3ead6340800ac15fbe76e223599a5b3dbc6b6b13b72b684919aa43487838564ad7117b4e67fa7f36f0f58554fd8b8d6233efbcb82e6927a0c31f22c6a9ab5dbb
|
||||
DIST monitoring-plugins-2.3.tar.gz 2528556 BLAKE2B d8c8886aea900a172e5693de766edb6b7ef7aac5ee94fec1f5c14cb0e9873623b14a965cc8852abb4ed44934d5111a86e130e7c37201a03de42bc996797302de SHA512 926065667dff6c608ae5b7da39f6416bfc2443b9e1cdef68cd5d19be99da1b6fc6f23ef87b05731312b5d7ad76d01f0242fc9e544dbb4dd00dbafa0e27434d2e
|
||||
EBUILD monitoring-plugins-2.3.ebuild 3026 BLAKE2B 5dcedf383de5985195d90e1d01194dd3414bc05f54b98a058d45bee42dfbcb3238b66d079d968e3912ef203a636182b11ff21c5328fd80359d56ccac965908ce SHA512 664b07c16bc3aae7b76202b4e446633c0df1832306bc315fffcad2f830a7b001a6829d9457b9d9cccf3230e9f49921229f4167b6ae3a407e23052468d4b2445f
|
||||
MISC metadata.xml 1404 BLAKE2B 68d3a914681db790872872cee7114b053aaa118b9eacbf33b02db932d3b970a80b0fc1d79d9e3f836f7d0f8870066bdf78b6b688864cac753d5ddf42a7ad9f9c SHA512 766657a0c9a0d16fa9fc0c052342b65c1f5b32dbbc0eb4e8fb014274b92dd0370dc19a6821ceed3979a1def5f429e1e3f23ccbf2ca443f787a50e00b503acf42
|
|
@ -1,102 +0,0 @@
|
|||
From d6bd787123aa9ccd96edec8286ec22dd0442c620 Mon Sep 17 00:00:00 2001
|
||||
From: Michael Orlitzky <michael@orlitzky.com>
|
||||
Date: Fri, 27 Oct 2017 07:58:43 -0400
|
||||
Subject: [PATCH 1/3] plugins/check_mysql*.c: define our own default MySQL
|
||||
port.
|
||||
|
||||
The MYSQL_PORT constant used to be defined in mysql.h, and was used as
|
||||
the default port in the two plugins check_mysql and check_mysql_query.
|
||||
Now that mysql.h no longer defines that constant, our plugins fail to
|
||||
build against newer versions of MySQL and MariaDB.
|
||||
|
||||
Since MYSQL_PORT used the "default port" on the local system, it
|
||||
actually was not the best choice as the default for the check plugins:
|
||||
when monitoring remote MySQL servers, the usual default of 3306 is
|
||||
more likely to be correct than whatever the local server happens to be
|
||||
listening on.
|
||||
|
||||
As a result, we fix the issue by defining our own constant, called
|
||||
CHECK_PORT_DEFAULT, as "3306" at the top of both check_mysql.c and
|
||||
check_mysql_query.c. The existing uses of MYSQL_PORT have been changed
|
||||
to use the new CHECK_PORT_DEFAULT.
|
||||
|
||||
This change is backwards-incompatible: any users who compiled in a
|
||||
MYSQL_PORT other than 3306 and who were running their checks on the
|
||||
same server as the database will now need to specify that port
|
||||
explicitly.
|
||||
|
||||
Closes: https://github.com/monitoring-plugins/monitoring-plugins/issues/1508
|
||||
---
|
||||
plugins/check_mysql.c | 8 ++++++--
|
||||
plugins/check_mysql_query.c | 8 ++++++--
|
||||
2 files changed, 12 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/plugins/check_mysql.c b/plugins/check_mysql.c
|
||||
index 5773afd9..c44919d0 100644
|
||||
--- a/plugins/check_mysql.c
|
||||
+++ b/plugins/check_mysql.c
|
||||
@@ -36,6 +36,10 @@ const char *email = "devel@monitoring-plugins.org";
|
||||
|
||||
#define SLAVERESULTSIZE 70
|
||||
|
||||
+/* The default port that MySQL servers listen on. */
|
||||
+#define CHECK_PORT_DEFAULT 3306
|
||||
+
|
||||
+
|
||||
#include "common.h"
|
||||
#include "utils.h"
|
||||
#include "utils_base.h"
|
||||
@@ -58,7 +62,7 @@ char *ciphers = NULL;
|
||||
bool ssl = false;
|
||||
char *opt_file = NULL;
|
||||
char *opt_group = NULL;
|
||||
-unsigned int db_port = MYSQL_PORT;
|
||||
+unsigned int db_port = CHECK_PORT_DEFAULT;
|
||||
int check_slave = 0, warn_sec = 0, crit_sec = 0;
|
||||
int ignore_auth = 0;
|
||||
int verbose = 0;
|
||||
@@ -505,7 +509,7 @@ void
|
||||
print_help (void)
|
||||
{
|
||||
char *myport;
|
||||
- xasprintf (&myport, "%d", MYSQL_PORT);
|
||||
+ xasprintf (&myport, "%d", CHECK_PORT_DEFAULT);
|
||||
|
||||
print_revision (progname, NP_VERSION);
|
||||
|
||||
diff --git a/plugins/check_mysql_query.c b/plugins/check_mysql_query.c
|
||||
index 49a14dd3..6f492442 100644
|
||||
--- a/plugins/check_mysql_query.c
|
||||
+++ b/plugins/check_mysql_query.c
|
||||
@@ -33,6 +33,10 @@ const char *progname = "check_mysql_query";
|
||||
const char *copyright = "1999-2007";
|
||||
const char *email = "devel@monitoring-plugins.org";
|
||||
|
||||
+/* The default port that MySQL servers listen on. */
|
||||
+#define CHECK_PORT_DEFAULT 3306
|
||||
+
|
||||
+
|
||||
#include "common.h"
|
||||
#include "utils.h"
|
||||
#include "utils_base.h"
|
||||
@@ -48,7 +52,7 @@ char *db_pass = NULL;
|
||||
char *db = NULL;
|
||||
char *opt_file = NULL;
|
||||
char *opt_group = NULL;
|
||||
-unsigned int db_port = MYSQL_PORT;
|
||||
+unsigned int db_port = CHECK_PORT_DEFAULT;
|
||||
|
||||
int process_arguments (int, char **);
|
||||
int validate_arguments (void);
|
||||
@@ -299,7 +303,7 @@ void
|
||||
print_help (void)
|
||||
{
|
||||
char *myport;
|
||||
- xasprintf (&myport, "%d", MYSQL_PORT);
|
||||
+ xasprintf (&myport, "%d", CHECK_PORT_DEFAULT);
|
||||
|
||||
print_revision (progname, NP_VERSION);
|
||||
|
||||
--
|
||||
2.13.6
|
||||
|
|
@ -1,39 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||
<pkgmetadata>
|
||||
<maintainer type="person">
|
||||
<email>hydrapolic@gmail.com</email>
|
||||
<name>Tomas Mozes</name>
|
||||
</maintainer>
|
||||
<maintainer type="person">
|
||||
<email>mjo@gentoo.org</email>
|
||||
<name>Michael Orlitzky</name>
|
||||
</maintainer>
|
||||
<maintainer type="project">
|
||||
<email>proxy-maint@gentoo.org</email>
|
||||
<name>Proxy Maintainers</name>
|
||||
</maintainer>
|
||||
<use>
|
||||
<flag name="dns">
|
||||
Install <pkg>net-dns/bind-tools</pkg> required for monitoring
|
||||
DNS servers. Disabling the flag does not remove any plugins.
|
||||
</flag>
|
||||
<flag name="game">
|
||||
Install <pkg>games-util/qstat</pkg> required for monitoring FPS
|
||||
servers. Disabling the flag does not remove any plugins.
|
||||
</flag>
|
||||
<flag name="fping">
|
||||
Install <pkg>net-analyzer/fping</pkg> required for fancy ping
|
||||
monitoring. Disabling the flag does not remove any plugins.
|
||||
</flag>
|
||||
<flag name="ssh">
|
||||
Install <pkg>net-misc/openssh</pkg> required for monitoring SSH
|
||||
servers. Disabling the flag does not remove any plugins.
|
||||
</flag>
|
||||
<flag name="snmp">
|
||||
Install <pkg>dev-perl/Net-SNMP</pkg> and
|
||||
<pkg>net-analyzer/net-snmp</pkg> required for monitoring SNMP
|
||||
values. Disabling the flag does not remove any plugins.
|
||||
</flag>
|
||||
</use>
|
||||
</pkgmetadata>
|
|
@ -1,104 +0,0 @@
|
|||
# Copyright 1999-2020 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
|
||||
inherit eutils flag-o-matic multilib user
|
||||
|
||||
DESCRIPTION="50+ standard plugins for Icinga, Naemon, Nagios, Shinken, Sensu"
|
||||
HOMEPAGE="https://www.monitoring-plugins.org/"
|
||||
SRC_URI="https://www.monitoring-plugins.org/download/${P}.tar.gz"
|
||||
|
||||
LICENSE="GPL-3"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64 ~arm ~arm64 sparc x86"
|
||||
IUSE="gnutls ipv6 ldap libressl mysql dns fping game postgres radius samba snmp ssh +ssl"
|
||||
|
||||
# Most of the plugins use automagic dependencies, i.e. the plugin will
|
||||
# get built if the binary it uses is installed. For example, check_snmp
|
||||
# will be built only if snmpget from net-analyzer/net-snmp[-minimal] is
|
||||
# installed. End result: most of our runtime dependencies are required
|
||||
# at build time as well.
|
||||
#
|
||||
# REAL_DEPEND contains the dependencies that are actually needed to
|
||||
# build. DEPEND contains those plus the automagic dependencies.
|
||||
#
|
||||
REAL_DEPEND="dev-lang/perl
|
||||
ldap? ( net-nds/openldap )
|
||||
mysql? ( dev-db/mysql-connector-c:= )
|
||||
postgres? ( dev-db/postgresql:= )
|
||||
ssl? (
|
||||
!gnutls? (
|
||||
!libressl? ( dev-libs/openssl:0= )
|
||||
libressl? ( dev-libs/libressl:= )
|
||||
)
|
||||
gnutls? ( net-libs/gnutls )
|
||||
)
|
||||
radius? ( net-dialup/freeradius-client )"
|
||||
|
||||
DEPEND="${REAL_DEPEND}
|
||||
dns? ( net-dns/bind-tools )
|
||||
game? ( games-util/qstat )
|
||||
fping? ( net-analyzer/fping )
|
||||
samba? ( net-fs/samba )
|
||||
ssh? ( net-misc/openssh )
|
||||
snmp? ( dev-perl/Net-SNMP
|
||||
net-analyzer/net-snmp[-minimal] )"
|
||||
|
||||
# Basically everything collides with nagios-plugins.
|
||||
RDEPEND="${DEPEND}
|
||||
!net-analyzer/nagios-plugins"
|
||||
|
||||
# At least one test is interactive.
|
||||
RESTRICT="test"
|
||||
|
||||
PATCHES=( "${FILESDIR}/define-own-mysql-port-constant.patch" )
|
||||
|
||||
src_configure() {
|
||||
append-flags -fno-strict-aliasing
|
||||
|
||||
# Use an array to prevent econf from mangling the ping args.
|
||||
local myconf=()
|
||||
|
||||
if use ssl; then
|
||||
myconf+=( $(use_with !gnutls openssl /usr)
|
||||
$(use_with gnutls gnutls /usr) )
|
||||
else
|
||||
myconf+=( --without-openssl )
|
||||
myconf+=( --without-gnutls )
|
||||
fi
|
||||
|
||||
# The autodetection for these two commands can hang if localhost is
|
||||
# down or ICMP traffic is filtered. Bug #468296.
|
||||
myconf+=( --with-ping-command="/bin/ping -4 -n -U -w %d -c %d %s" )
|
||||
|
||||
if use ipv6; then
|
||||
myconf+=( --with-ping6-command="/bin/ping -6 -n -U -w %d -c %d %s" )
|
||||
fi
|
||||
|
||||
econf \
|
||||
$(use_with mysql) \
|
||||
$(use_with ipv6) \
|
||||
$(use_with ldap) \
|
||||
$(use_with postgres pgsql /usr) \
|
||||
$(use_with radius) \
|
||||
"${myconf[@]}" \
|
||||
--libexecdir="/usr/$(get_libdir)/nagios/plugins" \
|
||||
--sysconfdir="/etc/nagios"
|
||||
}
|
||||
|
||||
DOCS=( ACKNOWLEDGEMENTS AUTHORS CODING ChangeLog FAQ \
|
||||
NEWS README REQUIREMENTS SUPPORT THANKS )
|
||||
|
||||
pkg_preinst() {
|
||||
enewgroup nagios
|
||||
enewuser nagios -1 /bin/bash /var/nagios/home nagios
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "This ebuild has a number of USE flags that determine what you"
|
||||
elog "are able to monitor. Depending on what you want to monitor, some"
|
||||
elog "or all of these USE flags need to be set."
|
||||
elog
|
||||
elog "The plugins are installed in ${EROOT%/}/usr/$(get_libdir)/nagios/plugins"
|
||||
}
|
Loading…
Reference in New Issue