spanning tree - looping basic question

Hi friends,

I have some trouble understanding a basic loop detection scenario in switched networks.

The topology is as follows: Host A | Segment A | (1/1) | (1/2) Switch A Switch B | (2/1) | (2/2) Segment B | Host B

Now if Host A on Segment A wants to communicate with Host B of Segment B, the packet goes to Switch A. Switch A adds entry for Host A in its MAC address table and broadcasts the frame to all its Switch ports except the port 1/1. Now Switch B hears the broadcast from Switch A and learns address of Host A through its port 2/2. Now it broadcasts on its port 1/2 which is heard by Switch A on 1/1. Now A again broadcasts through 2/1 and the loop continues. My questions are:

  1. If B responds to the broadcast, then does the loop stop?
  2. If Switch A and Switch B listen to each other's broadcasts, then how are they exactly connected? Are they connected to each other directly? I am not able to understand how would they be physically connected to hear each other's broadcasts?

Thanks a lot Gautam

Reply to
gautamzone
Loading thread data ...

"segment A" is a collision domain or similar - so it is also recieved by host B

Switch A adds entry for Host A in its

without spanning tree B will do the same, so 2 copies arrive at host B.

Now Switch B hears the broadcast from Switch A and

it doesnt have to be a broadcast.

at this point switch B think host A is on segment B - because it "saw" a packet with host A mac address. Switch A is transparent - which means it cannot put a marker in the packet to show the packet was just forwarded by a switch.....

B is now confused since it has seen indications of host A on 2 different ports with a few mSec or uSec between them

either B will complain, shut down a port or 2 and break the loop, or merrily forward the copy back towards host A. Meanwhile switch A is doing exactly the same with the copy via B.

so - 2 switches in parallel act as a packet replicator, and will spawn copies until they hit some sort of limit - with modern switch hardware, that is often the bandwidth on the attached LANs.

Now it broadcasts on its

at this point you are confusing unicast and broadcast packets.

My questions are:

No

your diagram implies a layer 1 ethernet topology for each segment - so a co-ax segment, or some sort of repeater.

in practice it wouldnt matter if each connection is a direct cable between 2 ports and the host is connected separately to the loop

the key issues are that you can trace a loop between ports on switches, something generates a packet to kick off replication, and that you dont have anything to stop the entire loop from forwarding packets in circles.

Reply to
stephen

Cabling-Design.com Forums website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.