I tested with the patch but unfortunately the same crash occurs. -----Original Message----- From: Jarno Rajahalme [mailto:jrajaha...@nicira.com] Sent: 2015-09-29 23:10 To: Ben Pfaff Cc: Daniel Swahn; Daniele Venturino; b...@openvswitch.org Subject: Re: [ovs-discuss] RSTP crash in Open vSwitch
> On Sep 28, 2015, at 9:13 PM, Ben Pfaff <b...@nicira.com> wrote: > > On Wed, Sep 23, 2015 at 11:31:31AM +0000, Daniel Swahn wrote: >> (gdb) frame 0 >> #0 0x00000000004291ca in rstp_run (ofproto=<optimized out>, >> ofproto=<optimized out>) at ofproto/ofproto-dpif.c:2278 >> 2278 bundle_move(((struct ofport_dpif >> *)rstp_get_old_root_aux(ofproto->rstp))->bundle, > > Thanks for the report. > > Jarno and Daniele, the code around line 2278 in v2.4.0 is this: > > if (rstp_shift_root_learned_address(ofproto->rstp)) { > bundle_move(((struct ofport_dpif > *)rstp_get_old_root_aux(ofproto->rstp))->bundle, > ((struct ofport_dpif > *)rstp_get_new_root_aux(ofproto->rstp))->bundle); > rstp_reset_root_changed(ofproto->rstp); > } > > Looking at lib/rstp*.[ch], I see some code that sets 'old_root_aux' > and 'new_root_aux'. I don't see any code that clears them or updates > them if something happens to invalidate them (that is, if a port gets > deleted or if its aux gets updated). I suspect that this may be the > problem here. > > Jarno or Daniele, can you confirm this? I looked into this, and it may be that we fail to move the RSTP state machine when removing a port. In rstp_port_unref(), we are setting the port state to RSTP_DISABLED, but are then removing and freeing the port without triggering any change in the RSTP state machine, so if this port was the root, the root aux would still point to the deleted ofport. Maybe this would help: _______________________________________________ discuss mailing list discuss@openvswitch.org http://openvswitch.org/mailman/listinfo/discuss