Presentation is loading. Please wait.

Presentation is loading. Please wait.

CS4470 Computer Networking Protocols

Similar presentations


Presentation on theme: "CS4470 Computer Networking Protocols"— Presentation transcript:

1 CS4470 Computer Networking Protocols
9/11/2018 CS Computer Networking Protocols 7. Network layer Huiping Guo Department of Computer Science California State University, Los Angeles

2 Outline Network layer overview Forwarding and routing
Network service model Virtual-circuits networks and datagram networks 7. Network layer CS470

3 Network layer overview
9/11/2018 Network layer overview Transport layer Transport layer Data Data Data Network layer Network layer H Data H datagram H H Data Link layer Link layer H H Data frame 7. Network layer CS470

4 Network layer overview (cont.)
Achieve communication between two hosts The two hosts may not be physically connected Make use of services provided by the link layer Get a datagram from link layer Provide services to the transport layer Network layer of the Internet--IP Connectionless, Best effort services 7. Network layer CS470

5 Network layer transport a packet from sending to receiving host
9/11/2018 Network layer application transport network data link physical transport a packet from sending to receiving host on sending side encapsulates packets into datagrams on receiving side, delivers packets to transport layer network layer protocols in every host, router router examines header fields in all IP datagrams passing through it network data link physical application transport network data link physical 7. Network layer CS470

6 Forwarding and routing
When a datagram arrives at a router’s input link, the router must move the datagram to the appropriate output link Router-local action of transferring a datagram from an input link interface to the appropriate output link interface Routing Network-wide process determines the end-to-end paths that datagrams take from source to destination Routing algorithms 7. Network layer CS470

7 Forwarding and routing
Analogy: Routing process of planning trip from source to dest Forwarding process of getting through single interchange Forwarding table Every router has a forwarding table Router does the forwarding based on the table Routing algorithm decides the content of the table 7. Network layer CS470

8 Interplay between routing and forwarding
1 2 3 0111 value in arriving packet’s header routing algorithm local forwarding table header value output link 0100 0101 1001 routing algorithm determines end-end-path through network forwarding table determines local forwarding at this router 7. Network layer CS470

9 Connection setup 3rd important function in some network architectures:
ATM, frame relay, X.25 before datagrams flow, two end hosts and intervening routers establish virtual connection routers get involved network vs transport layer connection service: network: between two hosts (may also involve intervening routers in case of VCs) transport: between two processes 7. Network layer CS470

10 Network service model Q: What service model for “channel” transporting datagrams from sender to receiver? example services for a flow of datagrams: in-order datagram delivery guaranteed minimum bandwidth to flow restrictions on changes in inter-packet spacing example services for individual datagrams: guaranteed delivery guaranteed delivery with less than 40 msec delay 7. Network layer CS470

11 Network layer service models:
Guarantees ? Network Architecture Internet ATM Service Model best effort CBR VBR ABR UBR Congestion feedback no (inferred via loss) no congestion yes Bandwidth none constant rate guaranteed minimum Loss no yes Order no yes Timing no yes 7. Network layer CS470

12 IP is Best Effort Delivery
9/11/2018 IP is Best Effort Delivery Does not guarantee to prevent Duplicate datagrams Delayed or out-of-order delivery Corruption of data Datagram loss Reliable delivery provided by transport layer Network layer - IP - can detect and report errors without actually fixing them 7. Network layer CS470

13 Datagram networks vs Virtual-circuit networks
datagram network provides network-layer connectionless service virtual-circuit network provides network-layer connection service 7. Network layer CS470

14 Virtual circuits “source-to-dest path behaves much like telephone circuit” performance-wise network actions along source-to-dest path call setup, teardown for each call before data can flow each packet carries VC identifier (not destination host address) every router on source-dest path maintains “state” for each passing connection link, router resources (bandwidth, buffers) may be allocated to VC (dedicated resources = predictable service) 7. Network layer CS470

15 VC implementation a VC consists of:
path from source to destination VC numbers, one number for each link along path entries in forwarding tables in routers along path packet belonging to VC carries VC number (rather than dest address) VC number can be changed on each link. new VC number comes from forwarding table 7. Network layer CS470

16 VC forwarding table VC routers maintain connection state information!
22 12 32 1 3 2 VC number interface number forwarding table in northwest router: Incoming interface Incoming VC # Outgoing interface Outgoing VC # … … … … VC routers maintain connection state information! 7. Network layer CS470

17 Virtual circuits: signaling protocols
used to setup, maintain teardown VC used in ATM, frame-relay, X.25 not used in today’s Internet application transport network data link physical application transport network data link physical 5. data flow begins 6. receive data 4. call connected 3. accept call 1. initiate call 2. incoming call 7. Network layer CS470

18 Datagram networks no call setup at network layer
routers: no state about end-to-end connections no network-level concept of “connection” packets forwarded using destination host address application transport network data link physical application transport network data link physical 1. send datagrams 2. receive datagrams 7. Network layer CS470

19 Datagram forwarding table
4 billion IP addresses, so rather than list individual destination address list range of addresses (aggregate table entries) routing algorithm local forwarding table dest address output link address-range 1 address-range 2 address-range 3 address-range 4 3 2 1 IP destination address in arriving packet’s header 1 2 3 7. Network layer CS470

20 Datagram forwarding table
Destination Address Range through otherwise Link Interface 1 2 3 7. Network layer CS470

21 Longest prefix matching
when looking for forwarding table entry for given destination address, use longest address prefix that matches destination address. Destination Address Range *** ********* ********* *** ********* otherwise Link interface 1 2 3 examples: DA: which interface? DA: which interface? 7. Network layer CS470

22 Datagram or VC network: why?
Internet (datagram) data exchange among computers “elastic” service, no strict timing req. many link types different characteristics uniform service difficult “smart” end systems (computers) can adapt, perform control, error recovery simple inside network, complexity at “edge” ATM (VC) evolved from telephony human conversation: strict timing, reliability requirements need for guaranteed service “dumb” end systems telephones complexity inside network 7. Network layer CS470


Download ppt "CS4470 Computer Networking Protocols"

Similar presentations


Ads by Google