[pve-devel] [PATCH pve-storage] Change zfspoolplugin path when snapshot is given.

Wolfgang Link w.link at proxmox.com
Thu Nov 19 09:27:21 CET 2015


Zfs subvol snapshots are always mounted under $path_of_subvol/.zfs/$snapname
---
 PVE/Storage/ZFSPoolPlugin.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/PVE/Storage/ZFSPoolPlugin.pm b/PVE/Storage/ZFSPoolPlugin.pm
index 0c1d8d9..91cc44f 100644
--- a/PVE/Storage/ZFSPoolPlugin.pm
+++ b/PVE/Storage/ZFSPoolPlugin.pm
@@ -154,7 +154,7 @@ sub path {
 	} else {
 	    $path = "/dev/zvol/$scfg->{pool}/$volname";
 	}
-	$path .= "\@$snapname" if defined($snapname);
+	$path .= "/.zfs/snapshot/$snapname" if defined($snapname);
     } else {
 	die "$vtype is not allowed in ZFSPool!";
     }
-- 
2.1.4




More information about the pve-devel mailing list