This patch looks good, except for the case where the ip address changes (specifically to 127.0.0.1 when an interface is taken out of service).
More work is needed probably in totemnet where totemnet maintains the the of node list and an iterator for them, and totemudpu_member_add adds state information to a context for the iteration. In any regard, that is somewhat difficult to test, so I'll merge this patch for now - keep in mind interface changes on the bindnetaddr will cause problems with udpu after this patch has been commmited. Reviewed-by: Steven Dake <[email protected]> On 06/08/2011 04:59 PM, Jiaju Zhang wrote: > Redundant ring has some problem in the UDP unicast mode. The problem > is the second ring has not been successfully initialized, that is, the > second time iface_changes happens, the member list for that interface > has not been added, which results in that ring cannot transmit normal > message. So the second ring cannot take over the work if the first > ring is down. This patch fixes this issue. > > Signed-off-by: Jiaju Zhang <[email protected]> > --- > exec/totemsrp.c | 12 +++++++----- > 1 files changed, 7 insertions(+), 5 deletions(-) > > diff --git a/exec/totemsrp.c b/exec/totemsrp.c > index 9f7f434..678fa64 100644 > --- a/exec/totemsrp.c > +++ b/exec/totemsrp.c > @@ -4421,17 +4421,19 @@ void main_iface_change_fn ( > "Created or loaded sequence id %lld.%s for this > ring.\n", > instance->my_ring_id.seq, > totemip_print (&instance->my_ring_id.rep)); > - for (i = 0; i < > instance->totem_config->interfaces[iface_no].member_count; i++) { > - totemsrp_member_add (instance, > - > &instance->totem_config->interfaces[iface_no].member_list[i], > - iface_no); > > - } > if (instance->totemsrp_service_ready_fn) { > instance->totemsrp_service_ready_fn (); > } > > } > + > + for (i = 0; i < > instance->totem_config->interfaces[iface_no].member_count; i++) { > + totemsrp_member_add (instance, > + > &instance->totem_config->interfaces[iface_no].member_list[i], > + iface_no); > + } > + > if (instance->iface_changes >= instance->totem_config->interface_count) > { > memb_state_gather_enter (instance, 15); > } > _______________________________________________ > Openais mailing list > [email protected] > https://lists.linux-foundation.org/mailman/listinfo/openais _______________________________________________ Openais mailing list [email protected] https://lists.linux-foundation.org/mailman/listinfo/openais
