[pve-devel] What ist plugin "list_images" used for

Fabian Grünbichler f.gruenbichler at proxmox.com
Thu Dec 15 09:30:25 CET 2016


On Wed, Dec 14, 2016 at 04:44:03PM +0100, Jasmin J. wrote:
> > No, you need to set that yourself if you want to test that.
> If there is no command to force it, is there an action to trigger it somehow?
> If not, why does it exist?

looks like dead code, unless I missed something:
- only called with $vollist set in PVE::Storage::vdisk_list(), where
  $vollist is a parameter as well (und passed unchanged)
- vdisk_list is never called with $vollist set, except for some
  ZFSPoolPlugin test cases

OTOH, it should be easy enough to implement (it's just a whitelist of
volumes that you should filter for), and if you want to test it a short
perl test script should be enough (replace the CAPS parts as needed):

use strict; use warnings; use Data::Dumper; use PVE::Storage;

my $scfg = PVE::Storage::config();
my $vollist = ["YOURSTORAGEID:VOLID1", "YOURSTORAGEID:VOLID2"];
print Dumper(PVE::Storage::vdisk_list($scfg, undef, undef, $vollist));





More information about the pve-devel mailing list