FAQ | This is a LIVE service | Changelog

Skip to content
Snippets Groups Projects
Commit 82023deb authored by Dr Adam Thorn's avatar Dr Adam Thorn
Browse files

Add generic thisproperty() in xymon script, analagous to thisquota()

parent a04d74be
No related branches found
No related tags found
No related merge requests found
......@@ -230,13 +230,19 @@ sub space($) {
}
sub thisquota($) {
sub thisproperty($$) {
my $zfs=shift;
my $quota=`sudo zfs get quota -Hp -ovalue $zfs`;
my $property=shift;
my $quota=`sudo zfs get $property -Hp -ovalue $zfs`;
chomp $quota;
return $quota;
}
sub thisquota($) {
my $zfs=shift;
return thisproperty($zfs, 'quota');
}
sub parentquota($) {
my $zfs = shift;
my $parent = join('/', (split('/', $zfs))[0..1]);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment