Review r The Internet IP Protocol Datagram format

  • Slides: 28
Download presentation
Review r The Internet (IP) Protocol Datagram format m IP fragmentation m ICMP: Internet

Review r The Internet (IP) Protocol Datagram format m IP fragmentation m ICMP: Internet Control Message Protocol m NAT: Network Address Translation r Routing in the Internet m Intra-AS routing: RIP and OSPF m Inter-AS routing: BGP m Some slides are in courtesy of J. Kurose and K. Ross

IP datagram format IP protocol version number header length (bytes) “type” of data max

IP datagram format IP protocol version number header length (bytes) “type” of data max number remaining hops (decremented at each router) upper layer protocol to deliver payload to how much overhead with TCP? r 20 bytes of TCP r 20 bytes of IP r = 40 bytes + app layer overhead 32 bits ver head. type of len service length fragment 16 -bit identifier flgs offset upper time to Internet layer live checksum total datagram length (bytes) for fragmentation/ reassembly 32 bit source IP address 32 bit destination IP address Options (if any) data (variable length, typically a TCP or UDP segment) E. g. timestamp, record route taken, specify list of routers to visit.

Why different Intra- and Inter-AS routing ? Policy: r Inter-AS: admin wants control over

Why different Intra- and Inter-AS routing ? Policy: r Inter-AS: admin wants control over how its traffic routed, who routes through its net. r Intra-AS: single admin, so no policy decisions needed Scale: r hierarchical routing saves table size, reduced update traffic Performance: r Intra-AS: can focus on performance r Inter-AS: policy may dominate over performance

Overview r Multicast Routing r Data Link Layer Services Some slides are in courtesy

Overview r Multicast Routing r Data Link Layer Services Some slides are in courtesy of J. Kurose and K. Ross

Multicast: one sender to many receivers r Multicast: act of sending datagram to multiple

Multicast: one sender to many receivers r Multicast: act of sending datagram to multiple receivers with single “transmit” operation m analogy: one teacher to many students r Question: how to achieve multicast Multicast via unicast r source sends N unicast datagrams, one addressed to each of N receivers routers forward unicast datagrams multicast receiver (red) not a multicast receiver (red)

Multicast: one sender to many receivers r Multicast: act of sending datagram to multiple

Multicast: one sender to many receivers r Multicast: act of sending datagram to multiple receivers with single “transmit” operation m analogy: one teacher to many students r Question: how to achieve multicast Network multicast r Router actively Multicast routers (red) duplicate and forward multicast datagrams participate in multicast, making copies of packets as needed and forwarding towards multicast receivers

Multicast: one sender to many receivers r Multicast: act of sending datagram to multiple

Multicast: one sender to many receivers r Multicast: act of sending datagram to multiple receivers with single “transmit” operation m analogy: one teacher to many students r Question: how to achieve multicast Application-layer multicast r end systems involved in multicast copy and forward unicast datagrams among themselves

Internet Multicast Service Model 128. 59. 16. 12 128. 119. 40. 186 multicast group

Internet Multicast Service Model 128. 59. 16. 12 128. 119. 40. 186 multicast group 226. 17. 30. 197 128. 34. 108. 63 128. 34. 108. 60 multicast group concept: use of indirection m hosts addresses IP datagram to multicast group m routers forward multicast datagrams to hosts that have “joined” that multicast group

Multicast groups q class D Internet addresses reserved for multicast: q host group semantics:

Multicast groups q class D Internet addresses reserved for multicast: q host group semantics: anyone can “join” (receive) multicast group o anyone can send to multicast group o no network-layer identification to hosts of members q needed: infrastructure to deliver mcast-addressed datagrams to all hosts that have joined that multicast group o

Joining a mcast group: two-step process r local: host informs local mcast router of

Joining a mcast group: two-step process r local: host informs local mcast router of desire to join group: IGMP (Internet Group Management Protocol) r wide area: local router interacts with other routers to receive mcast datagram flow m many protocols (e. g. , DVMRP, MOSPF, PIM) IGMP wide-area multicast routing IGMP

Multicast Routing: Problem Statement r Goal: find a tree (or trees) connecting routers having

Multicast Routing: Problem Statement r Goal: find a tree (or trees) connecting routers having local mcast group members m m m tree: not all paths between routers used source-based: different tree from each sender to rcvrs shared-tree: same tree used by all group members Shared tree Source-based trees

Approaches for building mcast trees Approaches: r source-based tree: one tree per source m

Approaches for building mcast trees Approaches: r source-based tree: one tree per source m shortest path trees m reverse path forwarding r group-shared tree: group uses one tree m minimal spanning (Steiner) m center-based trees

Shortest Path Tree r mcast forwarding tree: tree of shortest path routes from source

Shortest Path Tree r mcast forwarding tree: tree of shortest path routes from source to all receivers m Dijkstra’s algorithm S: source LEGEND R 1 1 2 R 4 R 2 3 R 3 router with attached group member 5 4 R 6 router with no attached group member R 5 6 R 7 i link used forwarding, i indicates order link added by algorithm

Reverse Path Forwarding q rely on router’s knowledge of unicast shortest path from it

Reverse Path Forwarding q rely on router’s knowledge of unicast shortest path from it to sender q each router has simple forwarding behavior: if (mcast datagram received on incoming link on shortest path back to center) then flood datagram onto all outgoing links else ignore datagram

Reverse Path Forwarding: example S: source LEGEND R 1 R 4 router with attached

Reverse Path Forwarding: example S: source LEGEND R 1 R 4 router with attached group member R 2 R 5 R 3 R 6 R 7 router with no attached group member datagram will be forwarded datagram will not be forwarded • result is a source-specific reverse SPT – may be a bad choice with asymmetric links

Reverse Path Forwarding: pruning r forwarding tree contains subtrees with no mcast group members

Reverse Path Forwarding: pruning r forwarding tree contains subtrees with no mcast group members m no need to forward datagrams down subtree m “prune” msgs sent upstream by router with no downstream group members LEGEND S: source R 1 router with attached group member R 4 R 2 P R 5 R 3 R 6 P R 7 P router with no attached group member prune message links with multicast forwarding

Shared-Tree: Steiner Tree r Steiner Tree: minimum cost tree connecting all routers with attached

Shared-Tree: Steiner Tree r Steiner Tree: minimum cost tree connecting all routers with attached group members r problem is NP-complete r excellent heuristics exists r not used in practice: m computational complexity m information about entire network needed m monolithic: rerun whenever a router needs to join/leave

Center-based trees r single delivery tree shared by all r one router identified as

Center-based trees r single delivery tree shared by all r one router identified as “center” of tree r to join: m edge router sends unicast join-msg addressed to center router m join-msg “processed” by intermediate routers and forwarded towards center m join-msg either hits existing tree branch for this center, or arrives at center m path taken by join-msg becomes new branch of tree for this router

Center-based trees: an example Suppose R 6 chosen as center: LEGEND R 1 3

Center-based trees: an example Suppose R 6 chosen as center: LEGEND R 1 3 R 2 router with attached group member R 4 2 R 5 R 3 1 R 6 R 7 1 router with no attached group member path order in which join messages generated

Overview r Multicast Routing r Data Link Layer Services Some slides are in courtesy

Overview r Multicast Routing r Data Link Layer Services Some slides are in courtesy of J. Kurose and K. Ross

Link Layer: Introduction Some terminology: r hosts and routers are nodes (bridges and switches

Link Layer: Introduction Some terminology: r hosts and routers are nodes (bridges and switches too) r communication channels that connect adjacent nodes along communication path are links m m m wired links wireless links LANs r Data unit is a frame, encapsulates datagram data-link layer has responsibility of transferring datagram from one node to adjacent node over a link “link”

Protocol layering and data Each layer takes data from above r adds header information

Protocol layering and data Each layer takes data from above r adds header information to create new data unit r passes new data unit to layer below source M Ht M Hn Ht M Hl Hn Ht M application transport network link physical destination application Ht transport Hn Ht network Hl Hn Ht link physical M message M segment M datagram M frame

Link layer: context r Datagram transferred by different link protocols over different links: m

Link layer: context r Datagram transferred by different link protocols over different links: m e. g. , Ethernet on first link, frame relay on intermediate links, 802. 11 on last link r Each link protocol provides different services m e. g. , may or may not provide rdt over link transportation analogy r trip from New York to Lausanne m limo: New York to JFK m plane: JFK to Geneva m train: Geneva to Lausanne

Link Layer Services r Framing, link access: m encapsulate datagram into frame, adding header,

Link Layer Services r Framing, link access: m encapsulate datagram into frame, adding header, trailer m channel access if shared medium m ‘physical addresses’ used in frame headers to identify source, dest • different from IP address! r Error Detection: m errors caused by signal attenuation, noise. m receiver detects presence of errors: • signals sender for retransmission or drops frame r Error Correction: m receiver identifies and corrects bit error(s) without resorting to retransmission r Half-duplex and full-duplex m with half duplex, nodes at both ends of link can transmit, but not at same time

Adaptors Communicating datagram sending node rcving node link layer protocol frame adapter r link

Adaptors Communicating datagram sending node rcving node link layer protocol frame adapter r link layer implemented in r receiving side “adaptor” (aka NIC) m looks for errors, rdt, flow control, etc m Ethernet card, PCMCI m extracts datagram, passes card, 802. 11 card to rcving node r sending side: m m encapsulates datagram in a frame adds error checking bits, rdt, flow control, etc.

Error Detection EDC= Error Detection and Correction bits (redundancy) D = Data protected by

Error Detection EDC= Error Detection and Correction bits (redundancy) D = Data protected by error checking, may include header fields • Error detection not 100% reliable! • protocol may miss some errors, but rarely • larger EDC field yields better detection and correction

Parity Checking Single Bit Parity: Detect single bit errors Two Dimensional Bit Parity: Detect

Parity Checking Single Bit Parity: Detect single bit errors Two Dimensional Bit Parity: Detect and correct single bit errors • Odd parity • Even parity 0 0

Internet checksum Goal: detect “errors” (e. g. , flipped bits) in transmitted segment (note:

Internet checksum Goal: detect “errors” (e. g. , flipped bits) in transmitted segment (note: used at transport layer only) Sender: r treat segment contents as sequence of 16 -bit integers r checksum: addition (1’s complement sum) of segment contents r sender puts checksum value into UDP checksum field Receiver: r compute checksum of received segment r check if computed checksum equals checksum field value: m NO - error detected m YES - no error detected. But maybe errors nonetheless? More later ….