> On Apr 21, 2017, at 8:52 AM, Jarno Rajahalme <[email protected]> wrote:
> 
>> 
>> On Mar 31, 2017, at 8:11 PM, nickcooper-zhangtonghao <[email protected] 
>> <mailto:[email protected]>> wrote:
>> 
>> When bridge stp enabled, we enable the stp ports despite
>> ports are down. When initializing, this patch checks
>> link-state of ports and enable or disable them according
>> to their link-state. This patch also allow user to enable
>> and disable a port when bridge stp is running.
>> 
> 
> This describes what the patch does but gives little help for understanding 
> why this change is needed. STP would notice that the link is down as it is 
> not able to exchange BPDUs over that link. Also, a link that is in 
> STP_DISABLED state forwards all traffic, so that when the link comes up, but 
> before stp_run() manages to enable STP there would be a loop in the network. 
> To prevent this it seems to me that we should leave STP enabled also when the 
> link goes down, so that STP would have the chance to initially block to port 
> when it comes back up.
> 
>  Jarno


Yes, STP would notice that the link is down as it is not able to exchange BPDUs 
over that link. If a link is down(e.g ifconfig eth0 down), it will not forward 
any traffic whenever stp port is STP_DISABLE or STP_ENABLE. And is there a loop 
in the network ? And if one interface is down, the command ‘ovs-appctl 
stp/show’ still show it(its role is designated and state is forwarding). The 
forwarding state of interface which is down, may confuse the users and 
developers.

I tested stp on cisco switch. If you shutdown the stp interface, you cannot get 
the interface info and the interface linked to it.

_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to