From 5fdc99f45e4f1bb7595a561cc413057b29a1734c Mon Sep 17 00:00:00 2001 From: jbjohnso Date: Thu, 17 Jun 2010 19:42:22 +0000 Subject: [PATCH] -Fix mistake in storage migration table save git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@6518 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/esx.pm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/xCAT-server/lib/xcat/plugins/esx.pm b/xCAT-server/lib/xcat/plugins/esx.pm index 322a43a9c..f531e0f8e 100644 --- a/xCAT-server/lib/xcat/plugins/esx.pm +++ b/xCAT-server/lib/xcat/plugins/esx.pm @@ -910,14 +910,14 @@ sub relocate_callback { my $state = $task->info->state->val; if ($state eq 'success') { my $vmtab = xCAT::Table->new('vm'); #TODO: update vm.storage? - my $prevloc = $tablecfg{vm}->{$node}->[0]->{storage}; + my $prevloc = $tablecfg{vm}->{$parms->{node}}->[0]->{storage}; my $model; ($prevloc,$model) = split /=/,$prevloc; my $target = $parms->{target}; - if ($prevloc) { - $target.="=$prevloc"; + if ($model) { + $target.="=$model"; } - $vmtab->setNodeAttribs($parms->{node},{storage=>$target); + $vmtab->setNodeAttribs($parms->{node},{storage=>$target}); sendmsg(":relocated to to ".$parms->{target},$parms->{node}); } else { relay_vmware_err($task,"Relocating to ".$parms->{target}." ",$parms->{node});