When a node with active or standby role sends peer info request, the node role 
will be saved.
This will avoid setting the active role to the new starting node.
---
 src/rde/rded/rde_main.cc | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/rde/rded/rde_main.cc b/src/rde/rded/rde_main.cc
index 977692c..aad9ba6 100644
--- a/src/rde/rded/rde_main.cc
+++ b/src/rde/rded/rde_main.cc
@@ -103,6 +103,9 @@ static void handle_mbx_event() {
       LOG_NO("Got peer info request from node 0x%x with role %s",
              msg->fr_node_id, Role::to_string(msg->info.peer_info.ha_role));
       CheckForSplitBrain(msg);
+      if(msg->info.peer_info.ha_role == PCS_RDA_ACTIVE || 
msg->info.peer_info.ha_role == PCS_RDA_STANDBY) {
+        role->SetPeerState(msg->info.peer_info.ha_role, msg->fr_node_id);
+      }
       SendPeerInfoResp(msg->fr_dest);
       break;
     }
-- 
1.9.1


------------------------------------------------------------------------------
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