computer networks - birla institute of technology and ... · computer networks about protocols,...
TRANSCRIPT
BITS Pilani Pilani | Dubai | Goa | Hyderabad
Computer Networks Lecture-3 January 12, 2012
Rahul Banerjee, PhD (CSE)
Professor, Department of Computer Science & Information Systems
E-mail: [email protected]
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956
A recap of the required and desirable features of / services by Computer Networks
About Protocols, Layers, Interfaces, Logical / Virtual Communication & Services
Of Network Architectures & Network Reference Models Examples Architecture of the Internet What is the Internet today? The Internet and the World-Wide Web Who decides about the Internet? Of The Internet, Intranet and Extranet Select References to the literature Summary
Interaction Points
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956
• Cost-effective and preferably controllable Resource Sharing • Includes:
• File-‐sharing, data-‐sharing, printer-‐sharing, display-‐sharing, computaCon-‐capability sharing, storage-‐sharing etc.
• Support for common services, • Bandwidth-‐sharing
• Scalability in terms of both connectivity and performance • Desired levels of configurable security (computationally
secure variant is what we aim for, where required) • Manageability
• In terms of monitoring, resource management, security management etc.
Required & Desirable Features of Computer Networks
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
4
Protocols, Services and Interfaces • Protocol: A set of rules and conventions that allow involved
entities to communicate meaningfully – formatting / encoding / decoding included, as required
• Channel: A path of communication – application-level logical / virtual communication path
• Services: Cohesive set of functionalities provided by a layer / protocol / entity
• Interfaces: A mechanism that allows communication between a pair of functional building blocks (like layers or modules or entities) using well-defined set of parameters involving functions calls or equivalents – Peer-to-Peer / Layer-to-Layer / entity-to-entity / module-to-module
• Service Access Points: defined addresses / ports through which data / parameters are passed
• Tunneling: Placing content into an enveloped way and passign it through a set of devices / entities without their requiring to know what is inside the envelope – involves Encapsulation & Decapsulation, may involve encryption and
decryption as well 12/01/12 (c) Dr. Rahul Banerjee, BITS Pilani, INDIA 4
Network Architecture & Reference Models
• Architecture versus Reference Model: A simplistic perspective: – Architecture: It may be seen as a detailed
generic blueprint with unambiguous definitions of services, interfaces, organization and defined protocols that helps in design and implementation of a set of relevant protocol stack / suite based network / internetwork
– Reference Model: It is the same as the architecture minus the specifically defined readily usable protocols.
Thursday 12 January 12 5 (c) Dr. Rahul Banerjee, BITS-‐Pilani, INDIA
An Example of the Network Architecture
• Example-1: – TCP/IP Architecture &
TCP/IP Reference Model
• Other Examples: – OSI Reference Model &
OSI Architecture – ATM Reference Model
& ATM Architecture – Our own Hypothetical
Reference Model (slide-5)
Thursday 12 January 12 6 (c) Dr. Rahul Banerjee, BITS-‐Pilani, INDIA
LLC Sub-layer
MAC Sub-layer
Physical layer
7
Data Link Layer
Physical Layer
Transport Layer
Network Layer
Applica3on Layer
Presenta3on Layer
Session Layer
The ISO OSI Reference Model
(c) Dr. Rahul Banerjee, BITS-‐Pilani, INDIA
8
The ISO OSI Reference Model
(c) Dr. Rahul Banerjee, BITS-‐Pilani, INDIA
Copyright: Dr. Rahul Banerjee BITS, Pilani (India) 9
Data Link Layer
Physical Layer
Transport Layer
Network Layer
Applica3on Layer
A Hypothetical Network Reference Model for Easy Conceptual Understanding
Layer-‐5
Layer-‐4
Layer-3
Layer-2
Layer-1
Often on the NIC card or chip
10
A Simplified Network Reference Model <for Instruction>
Host-1 Host-2
Application Layer Application Layer
Upper Layer-‐to-‐ Lower Layer Interface Upper Layer-‐to-‐ Lower Layer Interface
Upper Layer-‐to-‐ Lower Layer Interface Upper Layer-‐to-‐ Lower Layer Interface
Upper Layer-‐to-‐ Lower Layer Interface Upper Layer-‐to-‐ Lower Layer Interface
Same Layer -to- Same Layer Virtual Communication Interface
Same Layer -to- Same Layer Virtual Communication Interface
Same Layer -to- Same Layer Virtual Communication Interface
Same Layer -to- Same Layer Virtual Communication Interface
Same Layer -to- Same Layer Physical Communication Interface
(c) Dr. Rahul Banerjee, BITS-‐Pilani, INDIA
Copyright: Dr. Rahul Banerjee BITS, Pilani (India) 11
Application Layer • Application Layer is a layer of the Network Architecture
that is primarily concerned with getting TPDU from the lower layer (usually Transport Layer) and delivering it to the Application and vice-versa (with or without explicit presentation and session management support).
• Examples: HTTP, DHCP, DNS, SNMP, FTP (in the context of the TCP/IP Architecture).
• Web-services, Video-on-Demand over the network, Video/Voice-conferencing over the network etc. are examples of Applications that reside atop the protocols belonging to this layer.
Copyright: Dr. Rahul Banerjee BITS, Pilani (India) 12
Application Layer Responsibilities
• It primarily deals with: – Accepting messages from
the Application Layer through the APIs
– Processing these messages and generating APDUs
– Deciding transport connection requirements (for further transmitting this DU after encapsulating it within an APDU)
– Passing this packet through the SAP to the lower layer (TL)
n It also deals with ... q AccepCng APDU from the lower
layer through the SAP q Processing the APDU q Removing the encapsulaCon and
passing the messages to the respecCve desCnaCon applicaCon
q Provide diagnosCc support for network monitoring, configuraCon, management and trouble-‐shooCng at the ApplicaCon Layer or lower layer
(c) Dr. Rahul Banerjee, BITS, Pilani, India 13
Transport Layer: What is it?
• Transport Layer is a layer of the Network Architecture that is primarily concerned with: – getting TPDU from the upper layer (usually
Application Layer) and – delivering it to the same layer at the intended
destination node (through the underlying Network Layer).
• Converse is also true of the targeted set of responsibilities of this layer.
(c) Dr. Rahul Banerjee, BITS, Pilani, India 14
Transport Layer Responsibilities <another perspective>
• It primarily deals with: – Accepting APDU from the
Application Layer through the Service Access Point (SAP)
– Processing these APDU – Deciding transport
connection requirements (for further transmitting this DU after encapsulating it within a TPDU)
– Passing this packet through the SAP to the lower layer (NL)
n It also deals with ... q AccepCng TPDU from the lower
layer through the SAP q Processing the TPDU q Removing the encapsulaCon and
passing the messages to the respecCve desCnaCon applicaCon
q Provide diagnosCc support for network monitoring, configuraCon, management and trouble-‐shooCng at the ApplicaCon Layer or lower layer
(c) Dr. Rahul Banerjee, BITS, Pilani, India 15
Network Layer • Network Layer is primarily concerned with getting NLDU / Packets from
the source node and delivering it to the intended destination node (through none or many intermediate nodes).
• Additional responsibilities of this layer include: – Providing support for connection-oriented / connectionless services as the
case may be (depending upon the protocol stack and need) – Provide diagnostic support for network monitoring, configuration,
management and trouble-shooting at the Network Layer or higher layer. • Packet handling, packet management, Routing are its major
responsibilities.
n In the context of packet rouCng, network layer structural design goals include: q Ensuring the shortest possible delay and thereby the highest throughput at the least
possible cost q Ensuring acceptably reliable packet delivery (may be opConal in some cases) q Ensuring secure packet delivery (may be opConal in some cases)
(c) Dr. Rahul Banerjee, BITS, Pilani, India 16
Data Link Layer
• Data Link Layer consists of two sub-layers: – Media Access Control (MAC) sub-layer & – Logical Link Control (LLC) sub-layer.
• Major Issues involved in the design of the Data Link Layer include: – Which services are to be provided to each of the adjacent
layers? – Exactly when to provide these services? – How to provide them? – To whom should they be provided?
(c) Dr. Rahul Banerjee, BITS, Pilani, India 17
Physical Layer
• Physical Layer deals with transmission of raw digital data using analog or digital signal.
• This layer is concerned with the logic type (negative or positive), amplitude of the signal, signal representation, bit-length, direction of transmission etc.
• It deals with connection-establishment and termination.
n This layer is, in a nutshell, a layer that deals with various electrical and mechanical characterisCcs of every physical component of a computer network.
n Exact electrical, mechanical and procedural Interface DefiniCon is therefore its responsibility.
n Choice and use of the physical medium are the Physical Layer Design Issues.
(c) Dr. Rahul Banerjee, BITS, Pilani, India 18
A Few More Networking Terms • Repeaters / Repeater Hubs / Shared Hubs: where usually Physical
layer / level exist with L1-protocol data unit (raw bits) regeneration and onward transmission
• Managed Hubs / Layer-2 Switching Hubs: where Physical and Data Link layers / levels exist with ability to handle and deliver Layer-2-protocol data unit (frame)
• Bridges: where Physical and Data Link layers / levels exist with L2-protocol data unit (frame) processing and forwarding
• Switches: where Physical and Data Link and / or Network (sometimes even higher) layers / levels exist with Layer-2 and / or Layer-3-protocol data unit (frame / packet) processing, switched routing / forwarding
• Routers: where Physical and Data Link and Network layers / levels exist with L3-protocol data unit (packet) processing, routing and forwarding
• Gateways: where two or more different networks meet and may require protocol / message translation capabilities
• Clouds: abstraction of node connectivity in the networking context <details hidden>
What is an Internetwork?
12/01/12 (c) Dr. Rahul Banerjee, SDET Unit, BITS-‐Pilani, INDIA 19 12/01/12 19
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA 20
Of the Internet, Intranet and Extranet
• The Global Public Internetwork: The Internet • The Wholly Owned / Private Internetwork:
Intranet • The Hybrid Internetwork-- private networks /
internetworks connected through the Internet: Extranet In the early stages of development, technologies used for the internetworks of all type were essentially the same, except probably at the lowest level. This situation is rapidly changing.
12/01/12
12/01/12 (c) Dr. Rahul Banerjee, BITS Pilani, INDIA 21
Architecture of the Internet
• Originally, it was a point-to-point WAN.
• Original architecture that led to ARPANET has evolved over the years that have passed by.
• It is loosely hierarchical. • Currently, Internet
architecture is largely governed by the IAB of the ISoc.
• Has many sub-organs which facilitate evolution and coordinated maintenance of the Internet.
• IESG steers the ISoc in a general way the engineering issues are resolved.
• IETF workgroups do the ground work and by a democratic process helps community in building up engineering solutions through IETF drafts and standards (RFCs) etc.
12/01/12 (c) Dr. Rahul Banerjee, BITS Pilani, INDIA 22
What is the Internet today? • Wide Area Network of variety of networks • Global • Public • Not transparent, as yet • Hybrid topology but largely hierarchical • No single controller • Internet Society (ISoc) oversees, assists --- does
not control • QoS, Security continue to have issues – partly at
least • Web, mail, commerce, education, entertainment,
sharing continue to dominate its application space
12/01/12 (c) Dr. Rahul Banerjee, BITS Pilani, INDIA 23
InteracCon Points • Examples of Types of Applications benefitting from Networking
– hard real-time, soft real-time, non-real-time / best-effort / delay-tolerant applications / services <with examples>
– case-study movie – Constituent networking components of a smart room setup
• The Internet & its Evolution • About Internet Architecture • Who decides about the Internet? • The Internet versus the World-Wide Web • Protocols, Layers, Interfaces, Virtual Communication and
Services • Select References to the literature • Questions and Answers / Summary
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA 24
ConvenConal ClassificaCon of Computer Networks
• Class One: Function-based classification
• Data Networks • Voice Networks • Multimedia Networks ……
• Class Two: Location-and-Distance-based classification
• Personal Area Networks (PANs)
• Local Area Networks (LANs)
• Metropolitan Area Networks (MANs)
• Wide Area Networks (WANs) ….
• Class Three: Forwarding-‐based classificaCon
• Switched Networks • Circuit-‐Switched Networks • Packet-‐Switched Networks
• Shared Networks • Hybrid Networks
• Class Four: Ownership-‐based classificaCon
• Public Networks • Private Networks • Virtual Private Networks
12/01/12
25
Comparing Computer Networks with Distributed Systems
• Terms Computer Network and Distributed System must NOT be used interchangeably since: – In the former, locations and elements of network
remain visible to the user; – In the latter, the underlying network remains
transparent to the user who sees the system as a large uni-processor system.
• Similar differences can be cited in case of Network Operating
Systems and Distributed Operating Systems.
12/01/12 (c) Dr. Rahul Banerjee, BITS Pilani, INDIA
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA 26
Local Area Internetwork / Intranet • Traditionally, a Campus Internetwork is a campus-wide
internetwork of individual LANs which may be geographically spread over the part or whole of a single campus. This sometimes called campus intranet.
• In common practice, the entire campus internetwork including its communication subnet is wholly owned by a single organization or institution.
• Usually, the campus internetworks use LAN technology; however, it is possible to use WAN technology, when so desirable.
• The latter may be desirable in some cases when the campus is very large and comprises of a vast set of buildings spread over it. Protocols used in both of these cases at the lower layers, are, generally, different. 12/01/12
Robert Metcafe’s Ethernet • The original Ethernet protocol proposed and
implemented by Robert Metcafe was actually based on 1-p CSMA/CD protocol
• It did have a scheme that allowed greedy access to the channel by a station which led to lower efficiency
• Schemes like Random Back-off / Exponential Back-off were devised to improve the efficiency to a certain extent
12/01/12 (c) Dr. Rahul Banerjee, SDET Unit, BITS-Pilani, INDIA 27
An Ethernet LAN
28 (c) Dr. Rahul Banerjee, BITS, Pilani, India
Personal Computer
WorkstaCon
WorkstaCon Workstation
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
Another Form of a Simple LAN
29 (c) Dr. Rahul Banerjee, BITS, Pilani, India
The Shared Ethernet hub
Personal Computer
Network Printer
WorkstaCon
WorkstaCon
Laptop Computer
WorkstaCon
Tablet PC
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
Frames: Factors that ma^er!
• Synchronization: Transmitter & Receiver need to be in sync
• Start Delimiter: Required to mark starting bit • End Delimiter: Required to mark the end bit • Control Information: Information suggesting data
handling and interpretation • Error Detection / Correction / Retransmission • Flow Control: Required for avoiding data loss
due to overflow at receiving end • Data Length: Needed if data-field is not of fixed
size 30 (c) Dr. Rahul Banerjee,
BITS, Pilani, India (c) Dr. Rahul Banerjee, BITS Pilani, INDIA
A Sample Frame Format
n-‐Byte Preamble Start-‐of -‐Frame Delimiter DesCnaCon Add. Source Address Length of Data
Data Field Pad Field
Checksum
31 (c) Dr. Rahul Banerjee, BITS, Pilani, India
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
Network Elements of a Node • A typical network node has following
hardware elements of relevance, at the least: – Processor (CPU) with / without registers / caches – Optional External Cache(s) – RAM (Main Memory) – ROM / PROM / EPROM / EEPROM / EAPROM – Optional Secondary / Tertiary Memory / Storage
(Flash, Disk, MBM etc.) – Network Adapter / Network Interface Controller – Slots / Ports for connectivity to other node(s) – Power-provisioning – Bus / Lines (Control, Address, Data, Power)
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
Elements of a Network Interface Controller / Network Adapter
• A Network Adapter / Interface Controller Unit / Chip / Dongle often comprises of the following elements: – Host bus / line / link – Control Status Registers (often called CSR or simply even as Control
Registers) • logically readable / writable by the CPU
– --à often, a copy of the contents of the CSR is located in some pre-specified location in memory making it simple for CPU to perform R/W operations, as per need
» --à Actual writing to the NIC’s CSR is done by the Device Driver though – Bus Interface Unit – Internal storage (buffer included) – Transceivers for transmission and reception at the physical level
• Data Transfer Methods: DMA (no worry for the CPU) or Programmed I/O (PIO) based Data Transfer (CPU needs to work herein) from the memory of the host node to the NIC / Adapter
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
A DiagrammaCc View of NIC
h^p://www.plxtech.com/images/about/news/images/image042505.gif
h^p://commons.wikimedia.org/wiki/File:Ethernet_NIC_100Mbit_PCI.jpg
h^p://www.dansdata.com/images/gigabit/gbcard440.jpg
h^p://www.altera.co.jp/products/ip/ampp/morethanip/images/m-‐mCp-‐10g_etherpcs_fig1.gif
Examples of Ethernet Adapters
Source: h^p://www.altera.co.jp/products/ip/ampp/morethanip/images/m-‐mCp-‐10g_etherpcs_fig1.gif (c)
36 (c) Dr. Rahul Banerjee, BITS, Pilani, India
Based on IEEE documents with instructional modifications Copyright: IEEE Inc., N.Y.
The IEEE 802.x Architecture and Specifications revisited
Operation of a Bridge with Two LANs
37
Source Destination
S
H
H H H
H H
H
Hub
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
12/01/12 (c) Dr. Rahul Banerjee, BITS Pilani, INDIA 38
An Example of a Switched Intranet
Some Common Layer-‐2 Switches Cisco L2 Managed Switches
© Cisco, Inc.
Fixed Lasers
Electronic Switches
GxG MEMS
Group 1
LxM Crossbar
Linecard 1
Linecard 2
Linecard L
Group 2
LxM Crossbar
Linecard 1
Linecard 2
Linecard L
LxM Crossbar
Linecard 1
Linecard 2
Linecard L
Group G
MxL Crossbar
Linecard 1
Linecard 2
Linecard L
Electronic Switches
Optical Receivers
Group 1
MxL Crossbar
Linecard 1
Linecard 2
Linecard L
Group 2
MxL Crossbar
Linecard 1
Linecard 2
Linecard L
Group G
GxG MEMS
GxG MEMS
GxG MEMS
1
2
3
M
Static MEMS
1
2
3
M
1
2
3
M
1
2
3
M
1
2
3
M
1
2
3
M
1
2
3
M
An Example of a Hybrid Switching Fabric
© Dr. Nick McKeown, Stanford University <modified version>
An Example of Network (LAN) Switches
Cisco Catalyst 3750 Series Switches
© Cisco, Inc.
Cisco Catalyst 4500 Series of Switches Cisco Catalyst 4500 Series Switches
(Used in several places in the Institute as Distribution Switches)
© Cisco, Inc.
Cisco Catalyst 6500 Series of Switches Cisco Catalyst 6500 Series
Switches
(One of these is OUR Core Switch located in the IPC
System Room)
© Cisco, Inc.
44
A Bus Topology based Computer Network
SHARED BUS
(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA
N1 N2 N3 N4
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
45
A Ring Topology based Computer Network
C
C
C
C
C
(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
46
A Ring Topology based Computer Network
C
C
C
C
C
(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
47
A Tree Topology based Computer Network
NC1 NC2
NC11
NR
NC21
NC22
NC12
(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
48
A Star Topology based Computer Network
C
C
C
Switch
(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA
S
N1
N2
N3
N4
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
(c) Dr. Rahul Banerjee, BITS, Pilani, India 49
Summary of Network Topologies • Bus Topology
– Shared – Switched
• Tree Topology • Ring Topology
– Single – Double
• Star Topology • Irregular Topology • Complete Topology
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA
Summary • Intranet: Completely private network of networks
• Wireline • Wireless
– Fixed – Mobile
• Hybrid • The Internet: Global public network of networks
• Wireline • Wireless
– Fixed – Mobile
• Hybrid • Extranet: Intranets interconnected via the Internet
Thursday 12 January 12 50 (c) Dr. Rahul Banerjee, BITS-‐Pilani, INDIA (c) Dr. Rahul Banerjee, BITS Pilani, INDIA 50
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956
Project BITS-Connect 2.0
References • Larry L. Peterson & Bruce S. Davie: Computer Networks: A Systems Approach,
Fifth Edition, Morgan Kaufmann / Elsevier, New Delhi, 2011. <System design approach>
• S. Keshav: Computer Networking: An Engineering Approach, Pearson Education, New Delhi, 1997.
• A. S. Tanenbaum: Computer Networks, Fifth Edition, Pearson Education, New Delhi, 2012. <Conceptual Approach>
• Y. Zheng and S. Akhtar: Networks for Computer Scientists and Engineers, Oxford University Press, New York, 2002. <Structural approach>
• A. Leon Garcia and I. Widjaja: Communication Networks: Fundamental Concepts and Key Architectures, Second Edition, Tata McGraw-Hill, New Delhi, 2004.
• Mohammed G. Gouda: Elements of Network Protocol Design, Wiley Student Edition, John Wiley & Sons (Pte.) Ltd., Singapore, 2004.
• Thomas G. Robertazzi: Computer Networks and Systems: Queuing Theory and Performance Evaluation, Third Edition, Springer-Verlag, New York, 2000. <Analytical approach>
© Dr. Rahul Banerjee, BITS, Pilani (India) 12/01/12 (c) Dr. Rahul Banerjee, BITS Pilani, INDIA 52
BITS Pilani Pilani | Dubai | Goa | Hyderabad
Thank you!
Rahul Banerjee
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956