add lvmthinscan to CLI

This commit is contained in:
Dietmar Maurer
2016-02-20 10:11:59 +01:00
parent 9d0cb810a0
commit 668f6d9faf
2 changed files with 9 additions and 1 deletions

View File

@ -239,7 +239,7 @@ __PACKAGE__->register_method ({
}});
__PACKAGE__->register_method ({
name => 'thinlvmscan',
name => 'lvmthinscan',
path => 'lvmthin',
method => 'GET',
description => "List local LVM Thin Pools.",
@ -270,6 +270,7 @@ __PACKAGE__->register_method ({
},
code => sub {
my ($param) = @_;
return PVE::Storage::LvmThinPlugin::list_thinpools($param->{vg});
}});

View File

@ -159,6 +159,13 @@ our $cmddef = {
printf "$rec->{vg}\n";
}
}],
lvmthinscan => [ "PVE::API2::Storage::Scan", 'lvmthinscan', ['vg'],
{ node => $nodename }, sub {
my $res = shift;
foreach my $rec (@$res) {
printf "$rec->{lv}\n";
}
}],
zfsscan => [ "PVE::API2::Storage::Scan", 'zfsscan', [],
{ node => $nodename }, sub {
my $res = shift;