mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-07-21 18:41:03 +00:00
- have some dirs
This commit is contained in:
parent
0b089ea777
commit
08346aac58
687 changed files with 0 additions and 0 deletions
91
plugins/lustre/lustre_abs
Executable file
91
plugins/lustre/lustre_abs
Executable file
|
@ -0,0 +1,91 @@
|
|||
#!/usr/bin/perl
|
||||
# -*- perl -*-
|
||||
|
||||
=head1 NAME
|
||||
|
||||
lustre_df_abs - Plugin to monitor Lustre 1.8.x (cluster FS) storage objects MDT,OST's
|
||||
usage in TB and/or G
|
||||
|
||||
=head1 CONFIGURATION
|
||||
Path to lfs binary. Configuration is done through $lfs_bin variable, for example
|
||||
by default $lfs_bin = "/usr/bin/lfs", see below.
|
||||
|
||||
=head1 NOTES
|
||||
|
||||
Monitoring node - lustre client with mounted lustre
|
||||
|
||||
=head1 VERSION
|
||||
|
||||
$Id: lustre_df_abs,v 1.3 2011/03/01 10:39:58 fenix Exp $
|
||||
|
||||
=head1 AUTHOR
|
||||
|
||||
Ropchan Sergey <fenix.serega@gmail.com>
|
||||
|
||||
=head1 LICENSE
|
||||
|
||||
GPLv2
|
||||
|
||||
=cut
|
||||
|
||||
|
||||
use Munin::Plugin;
|
||||
|
||||
my $lfs_bin = "/usr/bin/lfs";
|
||||
|
||||
if ($ARGV[0] and $ARGV[0] eq "autoconf") {
|
||||
if (-r $lfs_bin) {
|
||||
print "yes\n";
|
||||
exit 0;
|
||||
} else {
|
||||
print "no ($lfs_bin found)\n";
|
||||
exit 0;
|
||||
}
|
||||
}
|
||||
|
||||
my @output = `$lfs_bin df`;
|
||||
|
||||
if ($ARGV[0] and $ARGV[0] eq "config") {
|
||||
print "graph_title Lustre cluster storage objects usage in TB\n";
|
||||
print "graph_args --base 1024 --lower-limit 0\n";
|
||||
print "graph_vlabel TB\n";
|
||||
print "graph_category lustre\n";
|
||||
|
||||
&print_labels;
|
||||
|
||||
exit 0;
|
||||
}
|
||||
|
||||
&print_values;
|
||||
|
||||
sub print_labels {
|
||||
for $_ (@output) {
|
||||
#storage objects
|
||||
if (/^\S+\s+\d+\s+(\d+)\s+\d+\s+\d+\%\s+\S+\[(.*)\:(\d+)\]/i) {
|
||||
my $name = $2.$3;
|
||||
print $name.".label ", $name, "\n";
|
||||
print $name.".min 0\n";
|
||||
print $name.".cdef ", $name,",1024,*\n";
|
||||
}
|
||||
|
||||
}
|
||||
print "summary.label summary", "\n";
|
||||
print "summary.min 0\n";
|
||||
print "summary.cdef summary,1024,*\n";
|
||||
}
|
||||
|
||||
sub print_values {
|
||||
for $_ (@output) {
|
||||
#storage objects
|
||||
if (/^\S+\s+\d+\s+(\d+)\s+\d+\s+\d+\%\s+\S+\[(.*)\:(\d+)\]/i) {
|
||||
my $name = $2.$3;
|
||||
print $name.".value ", $1, "\n";
|
||||
}
|
||||
|
||||
#summanary info
|
||||
if (/^filesystem summary\:\s+\d+\s+(\d+)\s+\d+\s+\d+\%\s+\S+\s/i) {
|
||||
print "summary.value ", $1, "\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
90
plugins/lustre/lustre_df
Executable file
90
plugins/lustre/lustre_df
Executable file
|
@ -0,0 +1,90 @@
|
|||
#!/usr/bin/perl
|
||||
# -*- perl -*-
|
||||
|
||||
=head1 NAME
|
||||
|
||||
lustre_df - Plugin to monitor Lustre 1.8.x (cluster FS) storage objects MDT,OST's
|
||||
usage in percents
|
||||
|
||||
=head1 CONFIGURATION
|
||||
Path to lfs binary. Configuration is done through $lfs_bin variable, for example
|
||||
by default $lfs_bin = "/usr/bin/lfs", see below.
|
||||
|
||||
=head1 NOTES
|
||||
|
||||
Monitoring node - lustre client with mounted lustre
|
||||
|
||||
=head1 VERSION
|
||||
|
||||
$Id: lustre_df,v 1.3 2011/03/01 10:39:58 fenix Exp $
|
||||
|
||||
=head1 AUTHOR
|
||||
|
||||
Ropchan Sergey <fenix.serega@gmail.com>
|
||||
|
||||
=head1 LICENSE
|
||||
|
||||
GPLv2
|
||||
|
||||
=cut
|
||||
|
||||
use Munin::Plugin;
|
||||
|
||||
my $lfs_bin = "/usr/bin/lfs";
|
||||
|
||||
if ($ARGV[0] and $ARGV[0] eq "autoconf") {
|
||||
if (-r $lfs_bin) {
|
||||
print "yes\n";
|
||||
exit 0;
|
||||
} else {
|
||||
print "no ($lfs_bin found)\n";
|
||||
exit 0;
|
||||
}
|
||||
}
|
||||
|
||||
my @output = `$lfs_bin df -h`;
|
||||
|
||||
if ($ARGV[0] and $ARGV[0] eq "config") {
|
||||
print "graph_title Lustre cluster storage objects usage in percent\n";
|
||||
print "graph_args --base 1000\n";
|
||||
print "graph_vlabel % usage\n";
|
||||
print "graph_scale no\n";
|
||||
print "graph_category lustre\n";
|
||||
|
||||
&print_labels;
|
||||
|
||||
exit 0;
|
||||
}
|
||||
|
||||
&print_values;
|
||||
|
||||
sub print_labels {
|
||||
for $_ (@output) {
|
||||
#storage objects
|
||||
if (/^\S+\s+\S+\s+\S+\s+\S+\s+(\d+)\%\s+\S+\[(.*)\:(\d+)\]/i) {
|
||||
my $name = $2.$3;
|
||||
print $name.".label ", $name, "\n";
|
||||
print $name.".min 0\n";
|
||||
print_thresholds($name,undef,undef,99,100);
|
||||
}
|
||||
}
|
||||
print "summary.label summary", "\n";
|
||||
print "summary.min 0\n";
|
||||
print_thresholds("summary",undef,undef,95,98);
|
||||
}
|
||||
|
||||
sub print_values {
|
||||
for $_ (@output) {
|
||||
#storage objects
|
||||
if (/^\S+\s+\S+\s+\S+\s+\S+\s+(\d+)\%\s+\S+\[(.*)\:(\d+)\]/i) {
|
||||
my $name = $2.$3;
|
||||
print $name.".value ", $1, "\n";
|
||||
}
|
||||
|
||||
#summanary info
|
||||
if (/^filesystem summary\:\s+\S+\s+\S+\s+\S+\s+(\d+)\%\s+\S+\s/i) {
|
||||
print "summary.value ", $1, "\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
96
plugins/lustre/lustre_df_free
Executable file
96
plugins/lustre/lustre_df_free
Executable file
|
@ -0,0 +1,96 @@
|
|||
#!/usr/bin/perl
|
||||
# -*- perl -*-
|
||||
|
||||
=head1 NAME
|
||||
|
||||
lustre_df_free - Plugin to monitor Lustre 1.8.x (cluster FS) storage objects MDT,OST's
|
||||
free space in TB and/or G
|
||||
|
||||
=head1 CONFIGURATION
|
||||
Path to lfs binary. Configuration is done through $lfs_bin variable, for example
|
||||
by default $lfs_bin = "/usr/bin/lfs", see below.
|
||||
|
||||
=head1 NOTES
|
||||
|
||||
Monitoring node - lustre client with mounted lustre
|
||||
|
||||
=head1 VERSION
|
||||
|
||||
$Id: lustre_df_free,v 1.3 2011/03/01 10:39:58 fenix Exp $
|
||||
|
||||
=head1 AUTHOR
|
||||
|
||||
Ropchan Sergey <fenix.serega@gmail.com>
|
||||
|
||||
=head1 LICENSE
|
||||
|
||||
GPLv2
|
||||
|
||||
=cut
|
||||
|
||||
|
||||
use Munin::Plugin;
|
||||
|
||||
my $lfs_bin = "/usr/bin/lfs";
|
||||
|
||||
if ($ARGV[0] and $ARGV[0] eq "autoconf") {
|
||||
if (-r $lfs_bin) {
|
||||
print "yes\n";
|
||||
exit 0;
|
||||
} else {
|
||||
print "no ($lfs_bin found)\n";
|
||||
exit 0;
|
||||
}
|
||||
}
|
||||
|
||||
my @output = `$lfs_bin df`;
|
||||
|
||||
if ($ARGV[0] and $ARGV[0] eq "config") {
|
||||
print "graph_title Lustre cluster storage objects free space in TB\n";
|
||||
print "graph_args --base 1024 --lower-limit 0\n";
|
||||
print "graph_vlabel TB\n";
|
||||
print "graph_category lustre\n";
|
||||
|
||||
&print_labels;
|
||||
|
||||
exit 0;
|
||||
}
|
||||
|
||||
&print_values;
|
||||
|
||||
sub print_labels {
|
||||
for $_ (@output) {
|
||||
#storage objects
|
||||
if (/^\S+\s+\d+\s+\d+\s+(\d)+\s+\d+\%\s+\S+\[(.*)\:(\d+)\]/i) {
|
||||
my $name = $2.$3;
|
||||
print $name.".label ", $name, "\n";
|
||||
print $name.".min 0\n";
|
||||
print $name.".cdef ", $name,",1024,*\n";
|
||||
}
|
||||
|
||||
}
|
||||
print "summary.label summary", "\n";
|
||||
print "summary.min 0\n";
|
||||
print "summary.cdef summary,1024,*\n";
|
||||
|
||||
print "total.label total", "\n";
|
||||
print "total.min 0\n";
|
||||
print "total.cdef total,1024,*\n";
|
||||
}
|
||||
|
||||
sub print_values {
|
||||
for $_ (@output) {
|
||||
#storage objects
|
||||
if (/^\S+\s+\d+\s+\d+\s+(\d+)\s+\d+\%\s+\S+\[(.*)\:(\d+)\]/i) {
|
||||
my $name = $2.$3;
|
||||
print $name.".value ", $1, "\n";
|
||||
}
|
||||
|
||||
#summanary info
|
||||
if (/^filesystem summary\:\s+(\d+)\s+\d+\s+(\d+)\s+\d+\%\s+\S+\s/i) {
|
||||
print "summary.value ", $2, "\n";
|
||||
print "total.value ", $1, "\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
90
plugins/lustre/lustre_df_indodes
Executable file
90
plugins/lustre/lustre_df_indodes
Executable file
|
@ -0,0 +1,90 @@
|
|||
#!/usr/bin/perl
|
||||
# -*- perl -*-
|
||||
|
||||
=head1 NAME
|
||||
|
||||
lustre_df_inodes - Plugin to monitor Lustre 1.8.x (cluster FS) storage objects MDT,OST's
|
||||
usage inodes in percents
|
||||
|
||||
=head1 CONFIGURATION
|
||||
Path to lfs binary. Configuration is done through $lfs_bin variable, for example
|
||||
by default $lfs_bin = "/usr/bin/lfs", see below.
|
||||
|
||||
=head1 NOTES
|
||||
|
||||
Monitoring node - lustre client with mounted lustre
|
||||
|
||||
=head1 VERSION
|
||||
|
||||
$Id: lustre_df_inodes,v 1.3 2011/03/01 10:39:58 fenix Exp $
|
||||
|
||||
=head1 AUTHOR
|
||||
|
||||
Ropchan Sergey <fenix.serega@gmail.com>
|
||||
|
||||
=head1 LICENSE
|
||||
|
||||
GPLv2
|
||||
|
||||
=cut
|
||||
|
||||
use Munin::Plugin;
|
||||
|
||||
my $lfs_bin = "/usr/bin/lfs";
|
||||
|
||||
if ($ARGV[0] and $ARGV[0] eq "autoconf") {
|
||||
if (-r $lfs_bin) {
|
||||
print "yes\n";
|
||||
exit 0;
|
||||
} else {
|
||||
print "no ($lfs_bin found)\n";
|
||||
exit 0;
|
||||
}
|
||||
}
|
||||
|
||||
my @output = `$lfs_bin df -i`;
|
||||
|
||||
if ($ARGV[0] and $ARGV[0] eq "config") {
|
||||
print "graph_title Lustre cluster storage objects inodes usage in percent\n";
|
||||
print "graph_args --base 1000\n";
|
||||
print "graph_vlabel % usage\n";
|
||||
print "graph_scale no\n";
|
||||
print "graph_category lustre\n";
|
||||
|
||||
&print_labels;
|
||||
|
||||
exit 0;
|
||||
}
|
||||
|
||||
sub print_labels {
|
||||
for $_ (@output) {
|
||||
#storage objects
|
||||
if (/^\S+\s+\S+\s+\S+\s+\S+\s+(\d+)\%\s+\S+\[(.*)\:(\d+)\]/i) {
|
||||
my $name = $2.$3;
|
||||
print $name.".label ", $name, "\n";
|
||||
print $name.".min 0\n";
|
||||
print_thresholds($name,undef,undef,99,100);
|
||||
}
|
||||
}
|
||||
print "summary.label summary", "\n";
|
||||
print "summary.min 0\n";
|
||||
print_thresholds("summary",undef,undef,95,98);
|
||||
}
|
||||
|
||||
&print_values;
|
||||
|
||||
sub print_values {
|
||||
for $_ (@output) {
|
||||
#storage objects
|
||||
if (/^\S+\s+\S+\s+\S+\s+\S+\s+(\d+)\%\s+\S+\[(.*)\:(\d+)\]/i) {
|
||||
my $name = $2.$3;
|
||||
print $name.".value ", $1, "\n";
|
||||
}
|
||||
|
||||
#summanary info
|
||||
if (/^filesystem summary\:\s+\S+\s+\S+\s+\S+\s+(\d+)\%\s+\S+\s/i) {
|
||||
print "summary.value ", $1, "\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue