From 48e27f7937dc58e1e70221f99f6c2b888631c93d Mon Sep 17 00:00:00 2001 From: Dietmar Maurer Date: Fri, 28 Aug 2015 11:01:41 +0200 Subject: [PATCH] scan_zfs: ignore subvolumes generated by our ZFSPoolPlugin --- PVE/Storage.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/PVE/Storage.pm b/PVE/Storage.pm index 9a313b0..d55b645 100755 --- a/PVE/Storage.pm +++ b/PVE/Storage.pm @@ -996,6 +996,8 @@ sub scan_zfs { my ($pool, $size_str, $used_str) = ($1, $2, $3); my $size = PVE::Storage::ZFSPoolPlugin::zfs_parse_size($size_str); my $used = PVE::Storage::ZFSPoolPlugin::zfs_parse_size($used_str); + # ignore subvolumes generated by our ZFSPoolPlugin + return if $pool =~ m!/subvol-\d+-[^/]+$!; push @$res, { pool => $pool, size => $size, free => $size-$used }; } });