CCM 4300 Lecture 3 Computer Networks, Wireless and Mobile Communications - PowerPoint PPT Presentation

1 / 75
About This Presentation

CCM 4300 Lecture 3 Computer Networks, Wireless and Mobile Communications


CCM 4300 Lecture 3 Computer Networks, Wireless and Mobile Communications Dr Enver Ever Room: T110 Dr. Enver Ever, Middlesex University * – PowerPoint PPT presentation

Number of Views:175
Avg rating:3.0/5.0
Slides: 76
Provided by: A10179


Transcript and Presenter's Notes

Title: CCM 4300 Lecture 3 Computer Networks, Wireless and Mobile Communications

CCM 4300 Lecture 3Computer Networks, Wireless
and Mobile Communications
  • Dr Enver Ever
  • Room T110

Session Content
  • Recap of last session
  • Introduction-objectives
  • Overview of interconnection components and
  • mechanisms
  • Overview of LANs
  • CSMA, CSMA/CD, Taking-turn / Round Robin
  • - Token Ring
  • Internet network layer
  • Internet transport layer
  • Internet application layer

Recap of Last Session
  • Defined and described how
  • Physical and Data links operate and work
  • Explained the LLC and MAC sub layers in the data
    link layer in the ISO Reference Model
  • Explained media access protocols and channel

Lesson objectives
  • At the completion of this lesson you should be
    able to
  • - understand interconnection devices,
    mechanisms, operations, and have a brief
    introduction to addressing.
  • - understand the Ethernet protocol and its frame
  • - describe the operation of CSMA/CD
  • - understand how the 802 IEEE standards form
    part of OSI Reference model
  • - describe how TCP/IP protocol layers relate to
    the ISO OSI 7 layer reference model
  • - describe the layers of the TCP/IP protocol and
    the purpose of each layer

OSI Reference Model
We defined a network as a collection of
computers and other devices. Collection
of computer networks or network of networks are
called an internetwork or internet
Individual networks comprising an internetwork
are called subnetworks Devices that
interconnect subnetworks are called intermediate
nodes (or intermediate systems) An
internetwork can involve - local networks
(e.g. LAN-to-LAN or LAN-to- mainframe) -
long-distance connections (e.g. LAN-to-WAN) -
WAN-to-WAN connections
Internetwork (LAN-to-LAN)
Intermediate Nodes
Subnetwork 1
Subnetwork 2
Network cloud consisting of many intermediate
Network hardware devices
Repeaters / Hubs Simplest level of
interconnection, operating at the bottom layer of
OSI (Layer 1) Suitable if - both sides of
the interconnection are identical - essentially
repeaters operating at bit levels - the
requirement is simply to repeat and boost all the
digital signal transmission across similar
media Some repeaters also provide re-timing
capabilities A Multiport Repeater is called a
Repeaters / Hubs - cont
The performance of a repeater does not
impact upon the network or its access
techniques - e.g. if the network operates at
10Mbps, so does the repeater Repeaters
operate at the bit level - typically introduces a
few bits delay whilst the signal is boosted
Media access techniques operate across the
extended network as if it were a single cable -
e.g the repeater does not separate CSMA/CD
access techniques on either side of it
IWUs Repeaters
  • Simple two-way amplifiers.
  • Distance limitation in local-area networks
  • Electrical signal becomes weaker as it
  • Imposes a limit on the length of a LAN
  • Clean up, amplify, and pass on bits.
  • Used to extend the length of LANs.
  • Functionality at the physical layer of the OSI
  • Media dependent and protocol independent
  • Normally confined to a single building.

IWUs Repeaters (2)
  • They provide no traffic isolation.
  • They generally provide no network monitoring
    tools, you will not want to use repeaters for a
    link that is likely to fail.
  • Maximum 4 Repeaters between source and
    destination (Ethernet).

Simple Repeater
  • Operates at a very low level.
  • Its primary purpose is to get around limitations
    in cable length.
  • Passes on individual bits in the signal (even
    collisions), without doing any processing at the
    packet level.
  • Note The basic Ethernet design requires that
    signals must be able to get from one end of the
    network to the other within a specified amount of
    time. This determines a maximum allowable

Buffered Repeater
  • Operates at the level of whole data packets.
  • It receives an entire packet from one network
    into an internal buffer and then retransmits it
    onto the other network.
  • Because such low-level features, as collisions
    are not repeated, the two networks continue to be
    separate as far as the Ethernet specifications
    are concerned.
  • Thus there are no restrictions on the number of
    buffered repeaters that can be used.
  • .

  • Multi-port repeaters.
  • Generally speaking, the term hub is used instead
    of repeater when referring to the device that
    serves as the centre of a star topology network
  • Repeaters and Hubs have the following limitations
  • Aggregate throughput is limited (Each bit is sent
  • Cannot support multiple LAN technologies
  • Limitations on maximum nodes and distances
  • .

Bridges / Switches
Link Layer (Layer 2) devices Designed to
connect IEEE 802.x LANs together and provide a
relay service at the MAC layer Bridge Store
and Forward - nodes connected to bridges share
bandwidth Switch (multiport bridge) Store
and Forward or Cut Through - Full-duplex
(switching matrix / switch port assigned MAC
address) - they have private connections
Bridges learn which hosts can be reached through
which interface maintains filtering tables -
when frame received, bridge learns location of
sender by adding sender location in filtering
  • Store and transmit packets.
  • Functionality at DLL so media dependent and
    protocol independent above the DL layer.
  • It is possible to use more repeaters by using
  • .

Bridges (2)
  • Bridges can determine whether the destination MAC
    address carried by data is a part of the same
    network segment as its source.
  • It makes no determination as to what network
    segment the data should be sent to.
  • Bridges indiscriminately pass data along to all
    other segments of the network.
  • This may cause broadcast storms.
  • Switch Multi-port bridge.
  • .

Bridge Learning example
Suppose C sends frame to D and D replies back
with frame to C
C 1 entry added
C sends frame, bridge has no information about D,
so floods to both LANs bridge notes that C is on
port 1 frame ignored on upper LAN frame
received by D
Bridge Learning example - cont
C 1
D 2 entry added
D generates reply to C, sends it bridge sees
frame from D bridge notes that D is on interface
2 bridge knows C on interface 1, so selectively
forwards frame out via interface 1
Network Layer (Layer 3) devices - address
used to route data (i.e. internet address)
WAN is clearly beyond the LANs domain - used to
interconnect two or more administratively
separate networks - each network can be set up
and operated without knowledge of the other
Routers are concerned with addressing
Routers - cont
Stores information about the whole network,
not just about a particular device Default
gateway is used to decrease the size of routing
table Different from hardware address used
in bridging Disadvantages - high cost
- high latency of the device router has to
analyse Layer 3 information
Routable and routing protocols
  • A routable (routed) protocol is a protocol that
    contains enough network layer addressing
    information for user traffic to be directed from
    one network to another one.
  • Routable protocols define the format and use of
    fields within a packet. Packets are delivered
    between networks.

Transmission Control Protocol/Internet Protocol
Internetwork Packet Exchange/Sequenced Packet
Exchange (IPX/SPX)
Windows 2000 Server
NetWare Client
Routed Network Environment
Segment 1
Segment 2


NetBIOS Enhanced User Interface (NetBEUI)
NetBEUI is a small, fast, and efficient protocol
that is limited to running on one segment.
Routing protocols
  • A routing protocol supports routed protocols to
    carry messages between networks.
  • Routing protocols are used exchange information
    between routers, but they do not carry any user
  • The exchange of information between routers is
    used to update routing tables maintained by
    routers and calculate the best path for packet
  • Interior gateway protocols (IGPs) Routing
    protocols that run inside an enterprise.
  • Examples RIP, IGRP, EIGRP, and OSPF.
  • Exterior gateway protocols (EGPs) Protocols that
    run outside an enterprise, or between autonomous
    systems (AS). (BGP4)

  • Static Routes
  • manually defined by the system administrator as
    the next hop to a destination.
  • useful for security and traffic reduction.
  • May contain alternative routes.
  • Default Routes
  • Manually defined by the system administrator as
    the path to take when no route to the destination
    is known.
  • Dynamic Routing

Interior routing protocols
  • Distance-vector routing protocol
  • Requires that a router informs its neighbours of
    topology changes periodically.
  • The routing table is passed to neighbour nodes
  • Calculates the direction and distance to any link
    in a network.
  • The cost of reaching a destination is calculated
    using various route metrics.
  • Link-state routing protocol
  • Performed by every switching node in the network
  • Every node constructs a map of the connectivity
    of the network, in the form of a graph.
  • The graph shows which nodes are connected to
    which other nodes
  • The cost of reaching a destination is calculated
    using various route metrics.
  • The collection of best next hops forms the node's
    routing table .
  • Only connectivity related information is passed.
    (not the whole routing table)

Interior routing protocols
  • RIP (Classful, V2 Classless)
  • A distance-vector routing protocol (also known as
    Bellman-Ford algorithms). originally specified in
    RFC 1058.
  • Key characteristics
  • Hop count is used as the metric for path
    selection. The maximum allowable hop count is 15.
    Routing updates are broadcast every 30 seconds by
  • Most widely used protocol on the Internet.
    Classful, v2 Classless
  • OSPF
  • A link-state routing protocol.
  • Support variable-length subnet masking (VLSM) and
    Classless Inter-Domain Routing (CIDR) addressing
  • The link-state (also called shortest path first)
    approach recreates the exact topology of the
    entire internetwork (or at least of the partition
    in which the router is situated).
  • Changes in the topology are detected very
  • It computes the shortest path tree for each route
    using a method based on Dijkstra's algorithm, a
    shortest path first algorithm.

Dijstras Algorithm
  1. Assign to every node a distance value. Set it to
    zero for our initial node and to infinity for all
    other nodes.
  2. Mark all nodes as unvisited. Set initial node as
  3. For current node, consider all its unvisited
    neighbours and calculate their distance (from the
    initial node). For example, if current node (A)
    has distance of 6, and an edge connecting it with
    another node (B) is 2, the distance to B through
    A will be 628. If this distance is less than
    the previously recorded distance (infinity in the
    beginning, zero for the initial node), overwrite
    the distance.
  4. When we are done considering all neighbours of
    the current node, mark it as visited. A visited
    node will not be checked ever again its distance
    recorded now is final and minimal.
  5. Set the unvisited node with the smallest distance
    (from the initial node) as the next "current
    node" and continue from step 3

Developed jointly Digital Equipment Corp.,
Intel Xerox Ethernet was a standard 1980s
Ethernet Blue Book and 1982 Ethernet Version
2.0 IEEE formed subcommittee 802.3 very
similar to Ethernet (V2.0) Due to IEEE
influences with U.S. and international
standardisation authorities, IEEE 802.3
eventually became ISO standard IS88023 The
two Ethernet specification are similar
technical difference are related to differences
in cable size, transceiver function, frame format
topology. So what is the bottom line!
In casual usage, IEEE 802.3 is commonly
referred to as Ethernet. What you should realise,
though is that technically it is not Ethernet
only V2.0 is considered Ethernet
CSMA Carrier Sense Multiple Access
CSMA listen before transmit Recap If
channel sensed idle transmit entire pkt If
channel sensed busy, defer transmission -
Persistent CSMA retry immediately with
probability p when channel becomes idle
continuously monitors the channel (may cause
instability) - Non-persistent CSMA retry after
random interval does not continuously monitor
the channel human analogy dont interrupt
CSMA/CD (Collision Detection)
  • CSMA/CD carrier sensing, deferral as in CSMA
  • - collisions detected within short time
  • - colliding transmissions aborted, reducing
    channel wastage
  • - persistent or non-persistent retransmission
  • collision detection
  • - easy in wired LANs measure signal strengths,
    compare transmitted, received signals
  • difficult in wireless LANs WHY?
  • receiver shut off while transmitting (more
    details later)
  • human analogy the polite conversationalist

(Carrier Sense Multiple Access with Collision
S 1 S 2 S 3
S 1 S 2 S 3
S 1 S 2 S 3
S 1 S 2 S 3
CSMA/CD Collisions
Station B
Station A
Frame from B
Frame from A
CSMA/CD collision detection
Jam Signal make sure all other transmitters
are aware of collision 48 bits Exponential
Back-off Goal adapt retransmission attempts to
estimated current load - heavy load random wait
will be longer first collision choose K from
0,1 delay is K x 512 bit transmission
times after second collision choose K from
0,1,2,3 after ten or more collisions,
choose K from 0,1,2,3,4,,1023
CSMA/CD Random-Access-Algorithm
Ethernet Frame Structure
Example Sending IP datagram on Ethernet LAN -
Sending adapter encapsulates IP datagram (or
other network layer protocol packet) in Ethernet
frame Preamble 7 bytes (wake up) with
pattern 10101010 followed by one byte (important
stuff) with pattern 10101011 used to
synchronise receiver, sender clock rates
This consists of 62 alternating 1's and 0's
followed by the pattern 11. Strictly speaking the
last byte which finished with the '11' is known
as the "Start of Frame Delimiter".
Ethernet Frame Structure - cont
Addresses 6 bytes, frame is received by all
adapters on a LAN and dropped if address does not
match Length / Type 2 bytes, indicates
length (value lt1500) or the higher layer
protocol (mostly IP but others such as Novell IPX
and AppleTalk may be supported) CRC 4 bytes,
checked at receiver, if error is detected, the
frame is simply dropped
Advantages / Disadvantages
Advantages - Fast Channel Access (for low
utilisation) - Stable, high redundancy (no need
for Segment Server or Monitor)
Disadvantages - No fixed runtimes, no
guaranteed service classes/capacity availabe
- Higher utilisation -gt more collisions
- "Unfair", stations can be blocked from sending
Taking-turns MAC Token Ring
Initially, chosen LAN architecture from
IBM IEEE 802.5 Token Ring LANs operate at 4
Mbit/s and 16Mbit/s Attached resources vary
from PCs to large computers Flow is
unidirectional Physical topology is usually a
star network, connecting each node back to a hub
(wire closet)
Token Passing
This technology is nearly extinct!
  • control token passed from one node to next
  • token message 3 octet
  • concerns
  • - token overhead
  • single point of failure (token)
  • a node might accidentally neglects to release

Advantages / Disadvantages
  • Advantages
  • - No Collisions
  • - Every station can send data within a fixed
  • - Flexible topology
  • - Effective / performant for large segments
  • Disadvantages
  • - Complicated protocol / difficult error
  • - Market acceptance

Random access / contention MAC
protocols efficient at low load single node can
fully utilize channel high load collision
overhead taking-turn / round robin
protocols look for best of both worlds!
channel partitioning / reservation MAC
protocols share channel efficiently at high
load inefficient at low load delay in channel
access, 1/N bandwidth allocated even if only 1
active node!
Where are we?
The Internet Network layer
Host, router network layer functions
The Internet Network layer - cont
Heart and soul of the Internet Protocol, the
IP of TCP/IP. Transfers user messages from
source to destination host. Connectionless
datagram service. Performs fragmentation and
re-assembly of datagrams. Relies on routers
and switches. Integral part is Internet
Control Message Protocol (ICMP) - uses an IP
datagram to carry messages about the state of
communication environment
Network layer functions
  • transport packet from sending to receiving
  • network layer protocols in
  • every host, router
  • Three important functions
  • path determination route taken by packets
    from source to dest.
  • Routing algorithms
  • switching move packets from
  • routers input to appropriate router output
  • call setup some network architectures
    require router call setup along path before data

Network service model
  • Q What service model for channel transporting
    packets from sender to receiver?

The most important abstraction provided by
network layer
virtual circuit or datagram?
guaranteed bandwidth? preservation of
inter-packet timing (no jitter)? loss-free
delivery? in-order delivery? congestion feedback
to sender?
service abstraction
Virtual circuits
  • source-to-dest path behaves much like telephone
  • 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 ID)
  • every router on source-dest. paths maintain
    state for each passing connection
  • - transport-layer connection only involved two
    end systems
  • link, router resources (bandwidth, buffers)
    may be allocated to VC
  • - to get circuit-like perf.

Datagram or VC network why?
  • Datagram
  • data exchange among computers
  • - elastic service, no strict timing req.
  • smart end systems (PCs)
  • - can adapt, perform control, error recovery
  • - simple inside network, complexity at edge
  • many link types
  • - different characteristics
  • - uniform service difficult
  • VC network
  • evolved from telephony
  • human conversation
  • - strict timing, reliability requirements
  • - need for guaranteed service
  • dumb end systems
  • - telephones
  • - complexity inside network

IPv4 Addresses
IP address 32-bit identifier for host,
router interface
  • Interface connection between host, router
    and physical link
  • routers typically have multiple interfaces
  • IP addresses associated with interface, not
    host, router

IP Addresses - cont
class-full addressing
class to
Large Networks A
host to
Medium-sized B to
Small networks C to
32 bits
IP Addresses - cont
IP Addresses - cont
Addressing Guidelines
Network ID Cannot Be 127 - 127 is reserved
for loopback functions (A zone that enables the
server to direct traffic to itself. The host
number is almost always Network
ID and Host ID Cannot Be 255 (All Bits Set to
1) - 255 is a broadcast address Network ID
and Host ID Cannot Be 0 (All Bits Set to 0) - 0
means this network only Host ID Must Be
Unique to the Network
IP datagram format
  • Version - 4bits
  • - Current version is 4
  • Internet Header Length (IHL) - 4bits
  • - To determine the beginning of data .
  • Type of Service (TOS) - 8bits
  • - first of 3 bits are used to indicate 1 of 8
    levels of priority (e.g. ftp, http, etc)
  • Total length - 16 bits
  • - length of IP datagram- The size of data is
    computed from the total length field and IHL .
  • - theoretical 65,535 bytes since 16bit

IP datagram format - cont
  • Identification - 16 bits
  • - to identify all fragments of a datagram.
  • Flags - 3 bits
  • - 2 bits - to control fragmentation
  • - 1 bit - unused
  • Fragment Offset - 13 bits
  • - Used in a fragmented datagram to indicate the
    position that the fragment occupies. Measured in
    64 bit units.

IP datagram format - cont
Time To Live (TTL) - 8 bits - prevents
datagrams to get routed in a loop .- If its set
to 0 , a router should discard the datagram.
Protocol - 8 bits - The transport layer
protocol carried by this datagram 17 - UDP6 -
TCP, 1 ICMP Header checksum - 16 bits It
protects only the header and not the
data recalculated every time it passes through a
router. Data Max. 65,535 bytes in length.
IP Fragmentation Reassembly
  • network links have MTU (max.transfer size) -
    largest possible link-level frame.
  • different link types, different MTUs
  • LANs generally 1500 bytes
  • WANs generally 576 bytes
  • large IP datagram divided (fragmented)
    within net
  • one datagram becomes several datagrams
  • reassembled only at final destination
  • IP header bits used to identify, order related

fragmentation in one large datagram out 3
smaller datagrams
Where are we?
The Internet Transport layer
  • Provides end-to-end data delivery services
  • The two most important protocols
  • Transmission Control Protocol (TCP)
  • - reliable data delivery service with
    end-to-end error correction and detection
  • User Datagram Protocol (UDP)
  • - low-overhead, connectionless datagram
  • Applications programmers can choose whichever
    service is more appropriate for their specific

TCP segment structure
TCP connection management
Initiates a connection
Accepts and acknowledges
Three-way handshake
Acknowledges and begins tx
4. Data flow begins
4. Receive data
3. ACK
3. ACK
1. SYN
1. SYN
TCP characteristics
A message is transmitted and then a
positive acknowledgement is being waited for
If the positive acknowledgement does not arrive
in certain period of time, the message is
retransmitted Messages are numbered in
sequence so that no one is being lost or
duplicated Messages are delivered at the
destination in the same order they were sent by
the source
TCP characteristics - cont
If data stream too large, the TCP protocol
will split it into several fragments and it makes
sure that all the fragments arrive correctly at
the other end for reassembly TCP can be
viewed as forming a library of routines that many
applications can use when they need reliable
network communication with an application on
another computer TCP provides also flow
control and congestion control
User Datagram Protocol (UDP)
no frills, bare bones Internet transport
protocol best effort service, UDP
segments may be - lost - delivered out of
order to application connectionless - no
handshaking between UDP sender, receiver - each
UDP segment handled independently of others
Why is there a UDP? no connection
establishment (which can add delay) simple
no connection state at sender, receiver
small segment header (8bytes) no congestion
control UDP can blast away as fast as desired
User Datagram Protocol (UDP) cont
often used for streaming multimedia
apps - loss tolerant - rate sensitive
reliable transfer over UDP add reliability at
application layer - application-specific error
32 bits
source port
dest port
Length, in bytes of UDP segment, including header
Application data (message)
UDP segment format
User Datagram Protocol (UDP) cont
1. Send data
2. Receive data
UDP checksum
  • Goal detect errors (e.g., flipped bits) in
    transmitted segment

Receiver compute checksum of received
segment check if computed checksum equals
checksum field value - NO - error detected - YES
- no error detected.
Sender treat segment contents as sequence
of 16-bit integers checksum addition (1s
complement sum) of segment contents sender
puts checksum value into UDP checksum field
You are mapping out the transmission of packets
from one station to another (TCP is used).
Packets 1-10 are sent. Packets arrived in the
following order 3,4,2,5,1,8,7,10,9. What packets
will be acknowledged and what, if any, will need
to be retransmitted?
A. Packets 5 and 10 will be acknowledged, and 6
will need to be transmitted B. Packet 5 will be
acknowledged and 6-10 will need to be
retransmitted C. Packets 1-5 and 7-10 will be
acknowledged, and 6 will need to be
retransmitted. D. All will be acknowledged and
none will need to be retransmitted since 6 can be
created based on information in the other packets.
Answer B The highest packet received will be
acknowledged. None of the packets above 6 can be
acknowledged until 6 has been received since only
an acknowledgement was sent for 5 that tells that
the sending stations 1-5 were received and
something has happened after that therefore it
will resend 6-10.
Where are we?
Application and application-layer protocols
  • Application communicating, distributed
  • running in network hosts in user space
  • exchange messages to implement application
  • e.g., email, ftp, Web
  • Application-layer protocols
  • one piece of an application
  • define messages exchanged by apps and actions
  • use communication services provided by lower
    layer protocols (TCP, UDP)
  • e.g., http defines how messages are passed
    between browser and web server

The TCP/IP architectures can be generalised
into 4 Layers
Application Layer
Consists of applications and processes that use
the network
Transport Layer
Provides end-to-end data delivery services
Internet Layer
Defines the datagram and handles the routing of
Consists of routing for accessing physical
Network Access Layer
Write a Comment
User Comments (0)