smfd crashes in updateImmAttr because it returned NO_RESOURCES.

PBE has not yet been disabled by smf, but smf is still trying to write to IMM.
See the ticket for how to reproduce the issue.

Don't re-enable PBE until commit.
---
 src/smf/smfd/SmfCampState.cc | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/smf/smfd/SmfCampState.cc b/src/smf/smfd/SmfCampState.cc
index 367dc54..3194a16 100644
--- a/src/smf/smfd/SmfCampState.cc
+++ b/src/smf/smfd/SmfCampState.cc
@@ -853,9 +853,6 @@ SmfCampResultT SmfCampStateExecuting::executeWrapup(
     SmfUpgradeCampaign *i_camp) {
   TRACE_ENTER();
 
-  // Activate IMM BPE if active when campaign was started.
-  i_camp->restorePbe();
-
   // Wait for IMM to become writable again by keep on writing until it
   // succeeds. Write the same value, just for synchronization purposes.
   changeState(i_camp, SmfCampStateExecuting::instance());
@@ -2246,6 +2243,9 @@ SmfCampResultT 
SmfCampRollbackCompleted::commit(SmfUpgradeCampaign *i_camp) {
 
   i_camp->removeRunTimeObjects();  // No action if it fails
 
+  // Activate IMM BPE if active when campaign was started.
+  i_camp->restorePbe();
+
   changeState(i_camp, SmfCampRollbackCommitted::instance());
   LOG_NO("CAMP: Upgrade campaign rollback committed %s",
          i_camp->getCampaignName().c_str());
-- 
2.9.5


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Opensaf-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensaf-devel

Reply via email to