Presentation is loading. Please wait.

Presentation is loading. Please wait.

Introduction to Computer Networks Spanning Tree 1.

Similar presentations


Presentation on theme: "Introduction to Computer Networks Spanning Tree 1."— Presentation transcript:

1 Introduction to Computer Networks Spanning Tree 1

2  Bridges transmit special messages (called configuration message) to each other.  A bridge will be elected as the root bridge.  Every bridge calculates the distance of the shortest path from itself to the root bridge.  For each LAN, select a designated bridge among the bridges residing on the LAN.  For each bridge, choose a port (root port) that lead to the root bridge.  Ports to be included in a spanning tree are the root ports and the ports on which self has been elected as designated bridge. Forming a Spanning Tree 2

3  A configuration message is transmitted by a bridge onto a port.  Received by all the other bridges on the LAN attached to the port.  It is not forwarded outside the LAN.  Contents:  Root ID: ID of the bridge assumed to be the root.  Bridge ID: ID of the bridge transmitting this configuration message.  Cost: Cost of the shortest path from the transmitting bridge to the root bridge.  Port ID: ID of the port from which the configuration message is transmitted. Forming a Spanning Tree 3

4  Comparing 2 configuration messages: C1 & C2  C1 is better than C2 if the root ID in C1 is lower than that in C2.  If the root IDs are equal  C1 is better than C2 if the cost in C1 is lower than that in C2.  If the root ID and cost are equal  C1 is better than C2 if its transmitting ID is lower than that in C2.  If the root ID, cost, and transmitting IDs are equal  C1 is better than C2 if its port ID is lower than that in C2. Forming a Spanning Tree - Rules 4

5 Forming a Spanning Tree - Example 5 B91 Port 1 Port 2 Port 3 Port 4 Port 5 810 14119125341123153411211124113901  Best known root – 41 (Root ID)  Cost – 12+1 = 13 (Lowest cost)  Root Port - 4 (Transmitting ID)  Designated Bridge on Ports 1 (root bridge) & 2 (cost)  Blocked Ports 3 & 5 (already connected to root)

6 Spanning Tree - Example 1B1, 11, B7, 2 2B1, 12, B2, 1 3B1, 12, B5, 5 4B1, 11, B17, 5 5B1, 12, B5, 3 6B1, 12, B4, 3 Root Bridge Cost Root Port Designated on Ports Blocked Ports B1 12 1 3 2,4,5,6 B5 Port 1 Port 2 Port 3 Port 4 Port 5 Port 6 6

7 Network Analysis 7 B11 B32 B76 B3 B15 B48 B12 B14 1 2 3 1 1 1 1 1 1 1 2 2 2 2 2 2 2 3 3 3 3 4 D D D R R D D D D R D R D R D R D D D

8  Bridges learn and cache the location of hosts.  A host may move / disappear  Important for a bridge to “forget” host locations  Unless frequently reassured that information is correct.  Done by timing out entries not been recently verified.  Timeout  Too long - traffic may not be delivered to the host at the new place.  Too short - wastes a lot of network bandwidth  Solution  A long value (e.g., 15 seconds) - used in the usual case, to reduce wasted network bandwidth.  A shorter value (e.g., forward delay) - used following a reconfiguration of the spanning tree algorithm Cache & Topology Changes 8

9  A bridge that detects a topology change will send a message to its parent.  This message will in turn be forwarded to the root bridge.  The root bridge set the topology change flag bit in its configuration messages  Sent (every hello time) downstream the spanning tree.  For a period that is forward delay + max age.  The bridges that receive this type of messages use the shorter timeout value for their caches  Until the flag is no longer set. Cache & Topology Changes 9

10 Network Analysis – Topology Change B11 B32 B76 B3 B15 B48 B12 B14 1 2 3 1 1 1 1 1 1 2 2 2 2 2 2 3 3 3 4 D D D R 2 R D D 3 D 1 D R D R D R D R D D D D R D 10


Download ppt "Introduction to Computer Networks Spanning Tree 1."

Similar presentations


Ads by Google