C SC 481.20 Lecture 9: Network Layer Introduction and Routers
major resource: Computer Networking (4th Edition),
Kurose and Ross, Addison Wesley, 2008
[ previous
| schedule
| next ]
Network Layer Introduction
Network Layer Service
- Move transport layer segments from sending host to receiving host
- Network Layer data unit is datagram or packet
- A datagram thus carries a segment as its payload
- Datagrams are forwarded from router to router
- Highway analogy: driving from intersection to intersection, making decision at
each that advances you toward your destination. Intersections are routers.
Major Issues
- Routing - determining path
- Forwarding - within router, getting data from input line to proper output line
- Connection setup and termination (virtual circuit service only)
- Service Model - different types are possible, combining 0 or more quality services:
- guaranteed delivery
- in-order delivery
- guaranteed bandwidth (x bytes delivered per second)
- guaranteed minimum jitter (small variation in time between packet deliveries)
- security
Major Levels of Service
- Virtual Circuit - connection-oriented
- Datagram - connectionless
Virtual Circuit Service
- Examples include ATM (Asynchronous Transfer Mode), X.25, frame relay
- Provides circuit-like (connection-oriented) network service using packet-switched network
- Each packet in a message follows same path
- Complex protocol for establishing path
- Each path is a Virtual Circuit (VC)
- Each packet carries a VC number in its header
- Each router in path has forwarding table entry for the VC
- Table entry has both Incoming VC# and Outgoing VC#
- Incoming VC# is normally different than Outgoing!
- Otherwise, all routers would have to agree on same VC# in advance!
- During VC setup, at each router the outgoing VC# is assigned and table entry created
- Once path established, transmission routing is fast and easy
- VC number in packet header is changed to Outgoing VC# as packet passes through router
- Router maintains state -- VC information in forwarding table entry
- State can include service variables (for e.g. guaranteed bandwidth)
- Circuit termination is easier; simply delete table entry in each router along path.
- Several service quality (QoS) levels are available to customer
- ADV: simple for transport layer
- DIS : complex protocols must be followed by all routers
- Good fit to telephony, because its networks are homogeneous, and its "transport layer" is telephones (traditionally very dumb)
- The fit is no coincidence, VC networks were built on telephone networks
Datagram Service
- A connectionless service
- Best example is IP (Internet Protocol)
- IP packets normally called datagrams
- Each packet separately routed
- Forwarding decision within router is based on destination address
- Router does not maintain state, so no setup/teardown
- Forwarding Table considerations
- not feasible to keep a table entry for every possible destination address!
- typically, the key field in each entry is an address prefix
- Forwarding decision: datagram destination address is matched against all prefixes
and chooses the one with longest prefix match
- Once key is matched, forward to corresponding output interface.
- "best effort" delivery, i.e. no guarantees
- ADV: simple, flexible for internetworking (interconnecting heterogeneous networks)
- DIS: places high demands on transport layer
- Good fit to Internet, because simplicity of datagram service facilitates communication
between dissimilar networks, and because Internet transport layer is in computers (potentially very smart)
- The fit is no coincidence, Internet protocols were designed to support heterogeneous networks
Routers
- Run only the bottom 3 protocol stack layers: network, link, physical
- Forwarding and routing are two different things (see above) but are related
- Forwarding table in router determines which output line an incoming datagram is switched to
- The forwarding table contents are determined by routing algorithm
- Each table entry is key-line pair: when incoming datagram matches key, is switched to corresponding output line
- Datagram header information used for table lookup.
- Router has 4 major components:
- Input ports, each of which has multiple subcomponents
- Physical layer component to receive incoming signals
- Link layer component, to extract the datagram
- Routing decision
- In decentralized approach, routing table lookup performed at
each input port
- In centralized approach, address sent to routing processor to perform lookup
- consider advantages and disadvantages of each
- Table contents determined by routing processor either way
- Consider alternative search techniques for lookup (longest prefix match)
- linear is out
- binary is possible (consider binary tree descent based on one level per bit value
e.g. high order bit selects left or right child of root, next bit selects child of that, etc)
- content addressable memory is most expensive but fastest - linear time
- can be supplemented with cache
- Queue for switching fabric, which may occur
- fabric which may be servicing another input port's request whose switching
path blocks this one (e.g. both have same output port)
- Packets will be dropped if queue is full
- Possibility for QoS: packets with higher priority may be placed at
front of queue, or may replace others if queue full
- Switching fabric
- Performs the actual switch from input to output port
- Several possible design strategies
- Shared memory - each output port gets its data from a specific memory location
and the routing table lookup produces the memory address.
- Shared bus - all output ports are on common bus and routing table lookup produces
the bus address.
- Crossbar switch - physical switching network arranged in 2D grid with input ports on
one dimension and output ports on the other
- Other physical interconnection network such as Omega switch
(see http://carbon.cudenver.edu/csprojects/CSC5809S01/Comm/omega.html for a diagram and nifty applet)
- The shared designs have obvious bottleneck considerations, the crossbar and Omega
networks can handle multiple switching operations simultaneously if they do not intersect
(e.g. common output port)
- Routing processor
- Runs algorithms to determine forwarding table contents
- We will consider it in greater detail later
- Output ports, each of which is mirror image of input port with several subcomponents
- Queue for output link; queuing may occur
- output link may be slower than switching fabric
- output link may be currently popular (destination for packets from
multiple input ports)
- Packets will be dropped if queue is full
- Possibility for QoS: packets with higher priority may be placed at
front of queue, or may replace others if queue full
- Link layer component for protocols with peer on input port
- Physical layer component to send output signal
- There are a variety of router designs but this is typical
[ C
SC 481 | Peter
Sanderson | Math Sciences server
| Math Sciences home page
| Otterbein ]
Last updated:
Peter Sanderson (PSanderson@otterbein.edu)