Accepting request 633222 from home:wrosenauer:devel

- update to 2.0.40
  * many fixes and improvements in plugins
  * fixes and improvements of the build system
- removed obsolete patch
  munin-plugin-quota_usage_warnings.patch

OBS-URL: https://build.opensuse.org/request/show/633222
OBS-URL: https://build.opensuse.org/package/show/server:monitoring/munin?expand=0&rev=43
This commit is contained in:
Wolfgang Rosenauer 2018-09-07 21:00:12 +00:00 committed by Git OBS Bridge
parent aea5c69d47
commit 723b6ca965
5 changed files with 16 additions and 69 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:aa93bd3415fc52e4c3b1c2fff58ec078e5d42fdc7202d38a8546bef97fcbd5b4
size 2242442

3
munin-2.0.40.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:e05c23ddada2a37ece2d6cd02202c88c981f31f64eba39392eb0d99a793dd28d
size 2252288

View File

@ -1,59 +0,0 @@
--- plugins/node.d.linux/quota_usage_.in.orig 2013-03-13 19:39:31.000000000 +0100
+++ plugins/node.d.linux/quota_usage_.in 2013-03-13 19:41:16.000000000 +0100
@@ -6,6 +6,11 @@
# ln -s), for example quota-usage_hda3. Use underscores instead of slashes, for
# example to monitor /dev/mapper/vol-foo, name this quota-usage_mapper_vol-foo
#
+# This plugin uses the soft and hard quota data for warning and critical
+# levels respectively.
+#
+# Source: https://svn.koumbit.net/koumbit/trunk/munin-plugins/quota-usage
+#
# Parameters understood:
#
# config (required)
@@ -28,7 +33,14 @@
chomp;
if (/^-+$/../^$/) {
my @data = split(/ +/);
- $users{$data[0]} = $data[2] if (@data > 2 && $data[2] > 0);
+
+ next if !$data[0] || $data[0] =~ /^#/;
+
+ if ( @data > 2 && $data[2] > 0 ) {
+ $users{$data[0]}[0] = $data[2]; # current usage
+ $users{$data[0]}[1] = $data[3]; # Soft quota
+ $users{$data[0]}[2] = $data[4]; # Hard quota
+ }
}
}
close REP;
@@ -45,15 +57,26 @@
$name = $user if (length($name) < length($user));
$user = clean_fieldname($user);
$name = (split(/,/, $name))[0];
+
printf "%s.label %s\n", $user, $name;
printf "%s.cdef %s,1024,*\n", $user, $user;
- printf "%s.graph no\n", $user if ($uid < 1000);
+
+ if ($users{$user}[1] && $users{$user}[1] > 0) {
+ printf "%s.warning %s\n", $user, $users{$user}[1];
+ }
+ if ($users{$user}[2] && $users{$user}[2] > 0) {
+ printf "%s.critical %s\n", $user, $users{$user}[2];
+ }
+
+ if ($uid < 200) {
+ printf "%s.graph no\n", $user
+ }
}
} else {
for my $user (@users_by_usage) {
my $esc = $user;
$esc = clean_fieldname($esc);
- printf "%s.value %s\n", $esc, $users{$user};
+ printf "%s.value %s\n", $esc, $users{$user}[0];
}
}

View File

@ -1,3 +1,12 @@
-------------------------------------------------------------------
Tue Sep 4 21:55:53 UTC 2018 - wr@rosenauer.org
- update to 2.0.40
* many fixes and improvements in plugins
* fixes and improvements of the build system
- removed obsolete patch
munin-plugin-quota_usage_warnings.patch
-------------------------------------------------------------------
Mon May 28 08:22:36 UTC 2018 - wr@rosenauer.org

View File

@ -12,7 +12,7 @@
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
@ -24,7 +24,7 @@
%define active_by_default 0
Name: munin
Version: 2.0.37
Version: 2.0.40
Release: 0
Summary: Network-wide graphing framework (grapher/gatherer)
License: GPL-2.0-only
@ -45,9 +45,7 @@ Source11: munin-cgi-html.service
Source12: nginx-munin.zip
# https://github.com/ifad/gsa-munin/archive/master.zip
Source13: gsa-munin.zip
# https://svn.koumbit.net/koumbit/trunk/munin-plugins/quota-usage
Patch: munin-plugin-quota_usage_warnings.patch
Patch3: perl526.patch
Patch1: perl526.patch
BuildRequires: html2text
BuildRequires: perl-HTML-Template
BuildRequires: perl-Log-Log4perl
@ -161,8 +159,7 @@ RRDtool. To see a real example of Munin in action, take a peek at
cp %{SOURCE1} .
unzip %{SOURCE12}
unzip %{SOURCE13}
%patch
%patch3 -p1
%patch1 -p1
%build
%__make HOSTNAME=yourhostname