Download presentation
Presentation is loading. Please wait.
1
Switch controller: Routing
Malathi Veeraraghavan University of Virginia Connectionless packet switch Routing Forwarding Summarized (aggregated) addresses Control path and data path Path computation: Dijkstra’s algorithm Examples used in practice
2
A network of connectionless packet switches
Control path: Routing (determine paths) Switch controllers exchange routing information Precompute forwarding tables Data path: Forwarding (send packets) Packets are switched from link to link across each switch
3
Goal of routing algorithms
Find "shortest" path on which to route packets or circuits, where the shortest path is determined by some metric, e.g.: minimum-weight path (add link weights) minimum end-to-end delay path with the most available bandwidth The algorithm should adapt to changes in topology (includes administrator-set link weights) reachability identify the switch through which a destination address can be reached destination could be several hops away loading conditions
4
Analogy In the roadways transportation network, where does a driver obtain the three types of routing information: topology information? reachability information? loading information? Topology information: Maps Reachability information: Maps Loading information: Radio broadcasts
5
Difference between topology and reachability information
Switch II Host III-B Host I-A Switch III Switch I Host III-C Switch IV Host IV-A Host IV-B Relative to Switch IV: Topology information: Switch IV has links to hosts IV-A & IV-B (in addition to links to other switches) Reachability information: Switch IV can reach hosts III-B and III-C, host I-A addresses that are more than one hop away implicit: reachability to directly connected hosts (part of topology information)
6
One approach: Routing protocol exchanges + Forwarding table precomputation
Link-state routing protocols Routing protocol exchanges Switch controllers send/receive routing protocol messages to exchange information about topology, reachability and loading conditions with each other Each switch controller thus acquires a picture of the whole network Forwarding table pre-computation Each switch controller then executes a shortest-path algorithm, such as Dijkstra's algorithm, to compute the shortest paths from its switch to all other switches Each switch controller then updates a forwarding table, which shows the next-hop and/or output port for each destination address
7
Summarized addresses What are summarized addresses?
An address that represents a group of endpoint addresses e.g., all 434 numbers, IP addresses Why summarize addresses? To reduce forwarding table sizes – hold one entry for a summarized address instead of a large number of individual addresses To reduce routing message lengths that convey reachability information
8
(will have other entries)
Control path: Routing protocol exchanges + forwarding table pre-computation Dest. Next hop III-B III-C II 4 5 1 Host I-A I Host III-B III Dest. Next hop III-* III IV Forwarding table (will have other entries) 1 1 IV Host III-C I, II, III, IV: switches Link weights are shown next to links Host interface addresses are derived from switch addresses (e.g. I-A is connected to switch I) A few example forwarding table entries shown at switches I, III, IV III-*: summarized address for all hosts connected to switch III
9
Data path: User-data transfer (e.g., packet destined to Host III-B)
Packet header Packet payload Dest. Next hop III-B III-C III-B II Host I-A III-B I III-B III-B III Host III-B IV Dest. Next hop III-* IV Host III-C Dest. Next hop III-* III Packet header carries destination host interface address (unchanged as it passes hop by hop) Each packet switch does a forwarding table lookup to determine the outgoing next hop switch
10
Next-hop and/or output ports in forwarding table
4 Switch II 5 Host III-B Host I-A b a Switch III Switch I 1 b c 1 a c Host III-C Switch IV 1 Dest. Next hop III-* IV Output port c e d Host IV-A Host IV-B link weight Forwarding table (will have other entries) Dest. Next hop Output port III-* III ? IV-A ? IV-B ? Forwarding table (will have other entries)
11
Forwarding table precomputation: Dijkstra’s algorithm
Find shortest paths from source node s to all other nodes. At each iteration, determine the “next closest node ” from the source s. For each node that is still not in set M (the set containing nodes to which shortest paths from the source have already been computed), determine if its current distance from s is shorter than the path routed via the selected “next closest node. ” Find the “next closest node” after finding all the distances. Move “next closest node ” into set M. When the set M has all the nodes, stop. "Node" in this application of Dijkstra's algorithm represents a network "Switch."
12
Dijkstra's algorithm s: source node.
wsn: administrator-set link weight for the link from node s to node n M = {s}; for each n M Dn = wsn; while (M all nodes) do Find i M for which Di = min{Dj ; j M}; Add i to M; Dn = mini [ Dn, Di + win ]; Update route; enddo
13
Example 1 2 3 4 5 6 Administrator-set link weights w56=2
14
List path weight and route
M D2 D3 D4 D5 D6 {1} 2, {1-2} 5, {1-3} 1, {1-4} 1 {1,4} 4, {1-4-3} 2 3 4 Simple shortest path: Only static administrator-set link weights considered Loading information not considered in this computation of shortest paths
15
Resulting forwarding table
Forwarding table at node 1 Destination Next Hop
16
Examples used in practice
Addressing IP-routed networks (e.g., Internet) 4-byte IP addresses Hierarchical addresses Address summarization done Ethernet switched network 6-byte MAC address Flat addresses No address summarization
17
Examples used in practice
IP-routed networks (e.g., Internet) Routing protocols Open Path Shortest First (OSPF) Border Gateway Protocol (BGP) Ethernet switched networks Forwarding table is built up as Ethernet frames are forwarded
18
Answer Dijkstra’s algorithm example
{1} 2, {1-2} 5, {1-3} 1, {1-4} 1 {1,4} 4, {1-4-3} 2, {1-4-5} 2 {1,4,2,5} 3, { } 4,{ } 3 {1,4,2,5,3} 4 {1,4,2,5,3,6}
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.