From 5db248d14eaf77f1205cdec6c921ad11104e4fa0 Mon Sep 17 00:00:00 2001 From: ertaozh Date: Thu, 10 May 2018 04:34:09 -0400 Subject: [PATCH] Force chain to be standby if only runcmd/ondiscover is specified for chain attribute --- xCAT-server/lib/xcat/plugins/destiny.pm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/xCAT-server/lib/xcat/plugins/destiny.pm b/xCAT-server/lib/xcat/plugins/destiny.pm index 3cc38c86c..6890a63bc 100755 --- a/xCAT-server/lib/xcat/plugins/destiny.pm +++ b/xCAT-server/lib/xcat/plugins/destiny.pm @@ -848,6 +848,10 @@ sub nextdestiny { } unless ($ref->{currchain}) { #If no current chain, copy the default $ref->{currchain} = $ref->{chain}; + } else { + if ($ref->{currstate} and ($ref->{currstate} eq $ref->{currchain})) { + $ref->{currchain} = 'standby'; + } } my @chain = split /[,;]/, $ref->{currchain};