1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-21 18:41:03 +00:00

Minor bugfixes

This commit is contained in:
Matt West 2013-03-16 10:01:44 +00:00
parent 88e207f51c
commit 667c62e346

View file

@ -499,7 +499,7 @@ if (defined $ARGV[0] && $ARGV[0] eq 'suggest') {
if (defined($s)) {
fetch_stats();
my @rootplugins = ('bytes','conns','commands','evictions','items','memory');
if ($stats{version} !~ /^1\.4\.[0-2]$/) {
if ($stats{version} !~ /^1\.4\.[0-7]$/) {
push(@rootplugins, 'unfetched');
}
foreach my $plugin (@rootplugins) {
@ -1012,7 +1012,7 @@ sub fetch_stats {
# Lets print the stats command and store the info from the output
print $s "stats\r\n";
while (my $line = <$s>) {
if ($line =~ /STAT\s(.+?)\s(.*)/) {
if ($line =~ /STAT\s(.+?)\s((\w|\d|\S)+)/) {
my ($skey,$svalue) = ($1,$2);
$stats{$skey} = $svalue;
}
@ -1021,7 +1021,7 @@ sub fetch_stats {
# Lets print the stats settings command and store the info from the output
print $s "stats settings\r\n";
while (my $line = <$s>) {
if ($line =~ /STAT\s(.+?)\s(.*)/) {
if ($line =~ /STAT\s(.+?)\s((\w|\d|\S)+)/) {
my ($skey,$svalue) = ($1,$2);
if ($skey eq 'evictions') {
$skey = 'evictions_active';