1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-22 14:16:00 +00:00

Fixed plugins/mysql/mysql_size_all to support database names with a "-" character

This commit is contained in:
clorch 2012-06-28 14:32:53 +03:00
parent a08c69ef8d
commit 970a09d158

View file

@ -171,9 +171,11 @@ sub getDBList {
my @dbs; my @dbs;
foreach my $f (glob("/var/lib/mysql/*")) { foreach my $f (glob("/var/lib/mysql/*")) {
if (-d $f) { if (-d $f) {
$f =~ s/\@002d/-/g;
$f =~ s!.*/!!; $f =~ s!.*/!!;
@dbs[$#dbs+1]=$f }; @dbs[$#dbs+1]=$f };
} }
return @dbs; return @dbs;
} }
#!/usr/bin/perl