Professional Documents
Culture Documents
Overview of Network: Layers
Overview of Network: Layers
Overview of Network: Layers
COURSE
COMPUTER NETWORKS
Chapter
1 Layers
OVERVIEW OF NETWORK
01
Reference: Peter L Dordal, “An Introduction to Computer Networks,” Jul 26, 2019
1. Layers 1. Layers
❖Application: software ❖Application:
you use.
Application layer
❖LANs (Local Area ❖LANs (Local Area
Networks): “physical” Networks):
Transport layer
networks that provide
the connection between
machines within a home, IP layer
school or corporation.
Logical LAN layer
(digital)
❖IP (Internet Protocol): provides an abstraction for ❖IP (Internet Protocol):
Physical LAN layer
connecting multiple LANs (e.g., into the Internet). (analog electrical, optical or
radio signaling mechanisms)
❖TCP (Transport Control Protocol): deals with transport ❖TCP (Transport Control
and connections and actually sending user data. Protocol):
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 3 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 4
1. Layers
❖A layer: corresponds to the idea of a programming
interface or library, with the understanding that a given
layer communicates directly only with the two layers
immediately above and below it.
NO interact
Application directly with the
Hands off a
chunk of data TCP library
IP and LAN layers .
2 Packet
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 5
2. Packet 2. Packet
? byte
❖Packets: modest-sized buffers of data, transmitted as a
unit through some shared set of links.
1 Ton
❖Header size (original):
➢Ethernet headers: 14 bytes.
➢IP headers: 20 bytes.
➢TCP headers: 20 bytes.
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 9 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 10
11 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 12
3. Data Rate, Throughput, Bandwidth, and Delay 3. Data Rate, Throughput, Bandwidth, and Delay
> >
❖Packets are the key to supporting shared transmission
Bandwidth Throughput Goodput lines; that is, they support the multiplexing of multiple
communications channels over a single cable.
Theoretical Transmission overhead Application
e.g., header data only
Bit by bit
without Protocol inefficiencies
delay e.g., synchronous,
retransmission
Competing traffic
e.g., network collision
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 13 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 14
3. Data Rate, Throughput, Bandwidth, and Delay 3. Data Rate, Throughput, Bandwidth, and Delay
❖When a router or switch receives a packet, it decides to ❖Bandwidth delay: a per-link delay.
what next node to forward it. ➢E.g., sending 1000 Bytes at 20 Bytes/millisecond will take 50
ms.
➢Need reads in the packet:
o Store-and-forward: reads in the entire packet ❖Propagation delay: on-link-transmission delay.
➢E.g., sending a packet on a 5000 km cable with a propagation
before forward a packet. speed of 200 m/µsec (= 200 km/ms, about 2/3 the speed
o Cut-through: read header and forward a packet of light), the first bit will not arrive at the destination until 25
ms later.
before it has fully arrived.
o Need queue (buffer). ❖Store-and-forward delay: equal to the sum of the bandwidth
delays out of each router along the path.
17 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 18
4. Datagram Forwarding
S1 S1 5 Topology
Destination Next hop Destination Next hop
A A
B B
C C
D D
E E
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 19 20
5. Topology (network analysis) 5. Topology (network design)
❖Network graph is acyclic, or is a tree ❖Physical Topology Diagrams: physical location of
intermediary devices and cable installation.
cable Room
installation
Rack
Shelf
✓ Network
presentation
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 23 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 24
6. Routing Loops
❖A potential drawback to datagram forwarding is the
possibility of a routing loop (cause some packets to
circulate endlessly).
➢ Consume a large majority of the bandwidth.
6
❖Routing loops can also occur in networks where the
Routing Loops underlying link topology is loop-free.
➢E.g., misconfiguration.
A R1 R1 C
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 27 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 28
7. Congestion
❖Packets arriving faster than they can be sent out.
➢Inbound interface has a higher bandwidth than the
outbound interface.
Queue
(buffer)
7
Full
Congestion
Dropped
Inbound outbound
interface interface
29 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 30
7. Congestion
➢On the Internet, most packet losses are due to
congestion.
o This is not because congestion is especially bad
(though it can be, at times), but rather that other
types of losses (e.g., due to packet corruption) are
insignificant by comparison.
8 LANs and Ethernet
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 33 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 34
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 35 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 36
8. LANs and Ethernet 8. LANs and Ethernet
❖Ethernet address: ❖Ethernet address:
➢Card’s physical address or hardware address or MAC ➢Switches must know where all active destination
(Media Access Control) address. addresses in the LAN are located; traditional Ethernet
o Broadcast address. (FF-FF-FF-FF-FF-FF) switches do this by a passive learning algorithm.
▪ If a switch receives a broadcast packet on one
port, it forwards the packet out every other port.
‐ i.e., allows host A to contact host B when A
does not yet know B’s physical address.
Fig. 16a. Switch
o Unicast address. Learning and
Forwarding [1].
▪ Traffic addressed to a particular host.
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 37 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 38
1. LEARNING 2. FLOODING
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 39 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 40
8. LANs and Ethernet 8. LANs and Ethernet
❖Ethernet address: ❖Ethernet address:
➢Switches must know where all active destination ➢Switches must know where all active destination
addresses in the LAN are located; traditional Ethernet addresses in the LAN are located; traditional Ethernet
switches do this by a passive learning algorithm. switches do this by a passive learning algorithm.
1. LEARNING 3. FORWARDING
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 41 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 42
9. IP - Internet Protocol
❖Network address:
➢IP addresses is the primary means of enabling devices
to locate one another and establish end-to-end
communication on the internet.
9
➢Unlike Ethernet addresses, are administratively assigned.
IP - Internet Protocol
➢IP version 4 (IPv4), IP version 6 (IPv6).
43 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 44
9. IP - Internet Protocol 9. IP - Internet Protocol
❖Network address: ❖To define the network and host portions of an address, a
➢An IP Version 4 address has two parts: devices use a separate 32-bit pattern called a subnet mask
o Network number
o Host number
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 47 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 48
9. IP - Internet Protocol
❖IP Forwarding
R1 R2
Network address Int Network address Int
10 Transport
R3 R4 R5
Network address Int Network address Int Network address Int
49 50
➢Data can arrive out of order. ➢Data can arrive out of order.
➢IP only supports sending to a specific host ➢IP only supports sending to a specific host
o No method to access multiple applications in one host o No method to access multiple applications in one host
(e.g., Email and web). (e.g., Email and web).
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 51 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 52
10. Transport 10. Transport
❖Solution: Transport layer ❖Solution: Transport layer
➢E.g., Transmission Control Protocol (TCP) ➢E.g., Transmission Control Protocol (TCP)
o reliability: TCP numbers each packet and keeps o stream-orientation: An application using TCP can
track of which are lost and retransmits them after a write 1 byte at a time, or 100 kB at a time; TCP will
timeout. It holds early-arriving out-of-order packets
for delivery at the correct time. Every arriving data buffer and/or divide up the data into appropriately
packet is acknowledged by the receiver; timeout and sized packets. (Segmentation)
retransmission occurs when an acknowledgment
packet isn’t received by the sender within a given o port numbers: these provide a way to specify the
time. receiving application for the data, and also to identify
o connection-orientation: Once a TCP connection is the sending application.
made, an application sends data simply by writing to
that connection. No further application-level
addressing is needed. TCP connections are managed o throughput management: TCP attempts to
by the operating-system kernel, not by the maximize throughput, while at the same time not
application. contributing unnecessarily to network congestion.
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 53 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 54
11
❖Open Systems Interconnection (OSI) protocols - This
Network Protocol Suites is a family of protocols developed jointly in 1977 by the
International Organization for Standardization (ISO) and the
International Telecommunications Union (ITU). The OSI
protocol also included a seven-layer model called the OSI
reference model. The OSI reference model categorizes the
functions of its protocols. Today OSI is mainly known for its
layered model. The OSI protocols have largely been
replaced by TCP/IP.
57 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 58
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 59 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 60
11. Network Protocol Suites 11. Network Protocol Suites
Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 61 Lecturer: Nguyen Viet Ha, Ph.D. - Department of Telecommunications and Networks, FETEL, HCMUS 62
QA
❖Explain the “stateless forwarding.” What is the opposite of
“stateless forwarding”? Give some examples.