From 034e4411bfcf6968f209c79022c4ac4fc8d398b5 Mon Sep 17 00:00:00 2001 From: Alexandre Derumier Date: Tue, 21 Aug 2012 14:43:44 +0200 Subject: [PATCH] nexenta: fix lun number parsing in sub path Signed-off-by: Alexandre Derumier --- PVE/Storage/NexentaPlugin.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/PVE/Storage/NexentaPlugin.pm b/PVE/Storage/NexentaPlugin.pm index 9352c74..b1a3516 100644 --- a/PVE/Storage/NexentaPlugin.pm +++ b/PVE/Storage/NexentaPlugin.pm @@ -198,7 +198,8 @@ sub path { my $map = nexenta_list_lun_mapping_entries($name,$scfg); die "could not find lun number" if !$map; my $lun = @$map[0]->{lun}; - + $lun =~ m/^(\d+)$/ or die "lun is not OK\n"; + $lun = $1; my $path = "iscsi://$portal/$target/$lun"; return ($path, $vmid, $vtype);