You are on page 1of 58

BITS Pilani

Pilani | Dubai | Goa | Hyderabad

Computer Networks
Lecture-6, January 23, 2013 Rahul Banerjee, PhD (CSE)
Professor, Department of Computer Science & Information Systems

E-mail: rahul@pilani.bits-pilani.ac.in

Interaction Points
How to discover what route your data is actually taking during its travel across the globe? Simple basics that go into programming for the network-based applications Briefly revisiting the TCP/IP Architecture Current State-of-the-art and Evolving Research Directions
From Clusters and Grids to Clouds Wearable Computing Ubiquitous or Pervasive Computing

Select References to the literature Summary


BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

How to Discover the Route Your Data Takes During Its Travel?
There do exist several techniques, commands and tools for discovering the actual route a unit of data (say a packet) has taken during its travel from your computer to the remote computer situated anywhere else in the world. A very common way to discover it at the user level is through the Traceroute command / utility. It may be known by slightly different names across operating systems like traceroute, tracert etc. Lets, now, see how does it work!
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

On MS-Windows, it looks like:

BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

On MacOS, it looks like:

BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

On Linux OS, it looks like:

BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

Simple Basics of Programming for Networkbased Applications


The application-processes of the simplest kind might involve a client-server relationship. APIs help!
All network-capable Operating Systems have some application programming interface (API) that makes application-to-application communication possible over networks without necessarily knowing intricate details of the underlying mechanisms. University of California at Berkeleys BSD Socket API is one of the most common APIs in use for writing such applications Lets us see how things work in this case, from programmers point of view!

BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

Basic Operations Involved


Server-side operations Client-side operations In each case, in the world of the Internet, we have, often, two basic choices to make:
Octet-stream-oriented reliable communication Datagram-oriented so-called unreliable communication Create a socket or an end-point on the server side Associate a transport port or a local address at which the application shall listen to incoming requests Enable and announce that server is ready to listen at this port with queue-size Accept any incoming (passive) connection request <blocks>
BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

Lets see the first type first!

Basic Operations Involved


At client-side: Create a socket or an end-point Send (passive) connection request to server Overall:

Connect <blocks> Send Receive <blocks> . Close

BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

Interaction Points
How to discover what route your data is actually taking during its travel across the globe? Simple basics that go into programming for the network-based applications Briefly revisiting the TCP/IP Architecture Current State-of-the-art and Evolving Research Directions
From Clusters and Grids to Clouds Wearable Computing Ubiquitous or Pervasive Computing

Select References to the literature Summary


BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

Thank you for your kind attention!


BITS Pilani
Pilani | Dubai | Goa | Hyderabad

Rahul Banerjee

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>

23/01/13

(c) Dr. Rahul Banerjee, BITS Pilani, INDIA

12

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


Wednesday, 23 January 13 23/01/13 (c) Dr. Rahul Banerjee, BITS-Pilani, ITS Pilani, INDIA 13 13

Concluding remarks
Networking support of some kind is already inside most of the operaJng systems we use today in variety of forms on Notebooks, Laptops, WorkstaJons and Servers. All Smart- phones and several set-top boxes support it too.
Subsequent lectures shall introduce you to the following topics:
Network Architectures Performance Quality of Service Reliability Security

23/01/13

(c) Dr. Rahul Banerjee, BITS Pilani, INDIA

14

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>

23/01/13

(c) Dr. Rahul BRahul anerjee, BITS Pilani, INDIA Dr. Banerjee, BITS, Pilani (India)

15

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.
Wednesday, 23 January 13 (c) Dr. Rahul Banerjee, BITS-Pilani, INDIA 16

The ISO OSI Reference Model

(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA

17

A Hypothetical Network Reference Model for Easy Conceptual Understanding



Layer-5

Applica?on Layer Transport Layer Network Layer Data Link Layer Physical Layer
18

Layer-4

Layer-3

Layer-2 Layer-1

Copyright: Dr. Rahul Banerjee BITS, Pilani (India)

Often on the NIC card or chip

A Simplified Network Reference Model <for Instruction>


Application Layer
Upper Layer-to- Lower Layer Interface Same Layer -to- Same Layer Virtual Communication 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 Upper Layer-to- Lower Layer Interface Upper Layer-to- Lower Layer Interface Same Layer -to- Same Layer Virtual Communication Interface

Application Layer
Upper Layer-to- Lower Layer Interface

Host-1

Same Layer -to- Same Layer Physical Communication Interface

Host-2

(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA

19

How does a WAN Look Like?

23/01/13

(c) Dr. Rahul Banerjee, BITS Pilani, INDIA

20

Architecture of the Internet 1 of 2


Brief Historical Notes:
Initiated by the US Department of Defense (DoD) through its Advanced Research Project Agency (ARPA) and was hence called ARPANet. Originally, it was a point-to-point WAN involving only four nodes across the USA. Original architecture that led to ARPANET has evolved over the years that have passed by. In later years, ARPA / DARPA dissociated with it and allowed to this to be blossomed into the Global Public Internet as we see it now.

Current Status:
It is loosely hierarchical. Has no single body that owns it or rigidly controls it. --Mostly run through volunteer efforts and by consensus. Runs several services, in a distributed manner, including the immensely popular World-Wide Web. Is helped by global cooperation including those from governments and corporates apart academia 23/01/13 (c) Dr. Rahul Banerjee, BITS Pilani, from INDIA 21

Architecture of the Internet 2 of 2


Currently, Internet architecture is designed for the besteffort delivery and is largely governed by the IAB of the Internet Society (ISoc).
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.

Currently, the TCP/IP stack is the dominant protocol stack over which the Internet runs. Keeping the needs of expansion and improvement, this protocol family has continually evolved over last 30+ years.
Current version of IP is IPv6, although IPv4 is still dominant in use.
(c) Dr. Rahul Banerjee, BITS Pilani, INDIA

23/01/13

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
23/01/13 (c) Dr. Rahul Banerjee, BITS Pilani, INDIA 23

Network Architecture of the Internet


ApplicaJon Layer

TCP (Transport) Layer

The Internet Layer The Host-to-Network Interface Link-Layer as per OSI Reference Model LLC Sub-layer MAC Sub-layer Physical layer

Physical-Layer as per OSI Reference Model


Wednesday, 23 January 13 (c) Dr. Rahul Banerjee, BITS-Pilani, INDIA

24

A Bus Topology based Computer Network

SHARED BUS

N1

N2

N3

N4

(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA

25

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 Backoff were devised to improve the efficiency to a certain extent

Robert Metcafes Ethernet

23/01/13

(c) Dr. Rahul Banerjee, SDET Unit, BITS-Pilani, INDIA

26

An Ethernet LAN
Personal Computer WorkstaJon Workstation WorkstaJon

27

(c) Dr. Rahul Banerjee, BITS, Pilani, India

A Ring Topology based Computer Network


C C

(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA

C C
28

A Ring Topology based Computer Network


C C

(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA

C C
29

A Tree Topology based Computer Network


NC12 NC21

NC11 NC1 NC2

NC22

NR

(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA

30

A Star Topology based Computer Network


N1
C

N4

S
N3

N2
Switch

(c) Dr. Rahul Banerjee, BITS-Pilani, INDIA

C
31

Another Form of Ethernet LAN


Personal Computer Tablet PC WorkstaJon WorkstaJon Network Printer Laptop Computer WorkstaJon The Ethernet Switch
(c) Dr. Rahul Banerjee, BITS, Pilani, India

32

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 33

Networks: A set of autonomous compute/communicaJon nodes interconnected for the purpose of meaningful resource sharing, require supporJng protocol stacks, not transparent to the users Clusters Homogeneous (pla_orm / OS), all involved nodes o`en belong to a single enJty and frequently designed for high-performance compuJng, may be limited to one or more racks within the same room (example: HPC clusters), easiest to deploy and manage Grids O`en heterogeneous (pla_orm / OS), Frequently spread over mulJple networks and network types, may involve single or mulJple organizaJons, require greater eort in deployment and administraJon Clouds May be public, private and hybrid, support mulJple levels of abstracJons / virtualizaJon, typically spread over wide areas, expected to be transparent to the user, oer the highest levels of redundancy / availability,

(c) Dr. Rahul Banerjee, BITS Pilani , INDIA

January 23, 2013

Of Clusters, Grids and Clouds A brief introducJon

(c) Dr. Rahul Banerjee, BITS Pilani , INDIA

VirtualizaJon is the underlying common technology involved in all the three paradigms Networking is the key enabler ingredient in each of these cases Cost-eecJveness, robustness and scalability improve as we move from cluster to cloud but overheads and internal complexity add up

January 23, 2013

A few points of signicance

Types of Clouds: ClassicaJon-1 <basis: model of operaJon>


Public Clouds (mulJ-tenancy, wide variaJons, mulJ- service, on-demand capacity addiJon a common feature) Private Clouds (single tenancy, limited variaJons, higher capital investments, greater control, more secure) Hybrid Clouds (near-opJmal best of both worlds, if congured well)

Types of Clouds: ClassicaJon-2 <basis: device virtualizaJon>


Infrastructure Cloud, ComputaJonal Cloud etc.

Types of Clouds: ClassicaJon-3 < basis: service virtualizaJon>


Pla_orm as a service, So`ware as a service, Storage as a service, CollaboraJon & Sharing Services etc.

(c) Dr. Rahul Banerjee, BITS Pilani , INDIA

January 23, 2013

Types of Clouds & Associated VirtualizaJon

Case-Study of of a Network-Based MulJ-site CollaboraJon System Design

Project BITS-Connect 2.0

BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

Project BITS-Connect 2.0 The Immersive Tele-presence Rooms


This is how an 18-seater immersive telepresence room looks like at all the Indian campuses. Chancellors oce is equipped with one two-seater system

BITS Pilani, Deemed to be University under Section 3 of UGC Act, 1956

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 L2protocol 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>
(c) Dr. Rahul Banerjee, BITS, Pilani, India 40

IPv4: The Header Structure


0
Ver. 4-bit IHL 4-bit Type of Service 8-bit Total Length 16-bit

31

Identification 16-bit

Flags 3-bit

Fragment Offset 13-bit

TTL 8-bit

Protocol Type 8-bit

Header Checksum 16-bit

Source Address 32-bit Destination Address 32-bit Options + Padding

Copyright: Dr. Rahul Banerjee BITS, Pilani (India)

41

IPv6: The Header Structure


0 4 16 31

Ver. TClass (4-bit) (8-bit) Payload Length (16-bit)

Flow Label (20-bit) Next Header Hop Limit (8-bit) (8-bit)

Source Address (128-bit) Destination Address (128-bit)


Copyright: Dr. Rahul Banerjee BITS, Pilani (India) 42

Frames: Link Layer (L-2) Data Units


Frame
The unit of Data as expressed at the Data Link Layer (Layer-2 of the Hypothe0cal model used for instruc0on) is convenJonally called a Frame.

Frames can take dierent formats and sizes depending upon the protocol in quesJon Frames do include elds like synchronizaJon, addressing, payload, control-informaJon etc. Frame Forwarding
The process of moving frames from one port to another in a bridge or switch.
43 (c) Dr. Rahul Banerjee, BITS, Pilani, India

Frames: Factors that maker!


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
44 (c) Dr. Rahul Banerjee, BITS, Pilani, India

A Sample Frame Format



n-Byte Preamble Start-of -Frame Delimiter DesJnaJon Add. Source Address Length of Data Data Field Pad Field Checksum

45

(c) Dr. Rahul Banerjee, BITS, Pilani, India

Logical View of a 10-Gbps Unit


Frame Structure - 10 Gigabit Ethernet (IEEE 802.3ae for LAN, WAN and MAN) It uses the same MAC frame as the Ethernet. 46=<15 00 Data unit + pad 7 Pre 1 SFD 6 DA 6 SA 2 Length Type 4 FCS

hkp://www.javvin.com/pics/10GigE.gif&imgrefurl=hkp://www.javvin.com/protocol10GigE.html&usg=__VuNx4T-UphUAzm- _AEsDqMqvzLQ=&h=374&w=576&sz=34&hl=en&start=10&um=1&itbs=1&tbnid=JlvKsLiP2xuOfM:&tbnh=87&tbnw=134&prev=/images%3Fq%3Dgigabit%2Bethernet%26hl%3Den%26safe%3Do%26um%3D1

hkp://www.ovislinkcorp.co.uk/linkd.GIF

Summary of Dierences Between L-2 Switches, Routers (L-3) and L-3 Switches
Bridges and Layer-2 switches divide the network into segments or micro-segments (apart from helping in Layer-2 protocol translaJon, management, security etc.) In eect, we can say that
Layer-2 Switches / Bridges separate collision domains Layer-2 Switches / Bridges can carry out protocol translaJons
23/01/13 (c) Dr. Rahul Banerjee, SDET Unit, BITS- Pilani, INDIA 47

Summary of Dierences Between L-2 Switches, Routers (L-3) and L-3 Switches
Routers are Layer-3 devices who handle Layer-3 packet rouJng within and outside the local network / internetwork and therefore eecJvely separate broadcast domains which end at its dierent network interfaces each of which carries a separate Subnet-idenJer / Subnet-address (apart from Layer-3 protocol translaJon, monitoring, security and management) Thus, in eect, we can say that:
Routers Separate broadcast domains (each of such broadcast domains which end at its dierent network interfaces each of which carries a separate Subnet-idenJer / Subnet-address ) Routers can carry out interior rouJng and / or exterior rouJng, depending upon their locaJon in the network Routers can carry out protocol translaJons (in terms of protocol-specic packet formats as well as in terms of allowing appropriately formaked selecJve data specic to rouJng protocols they may support).
23/01/13 (c) Dr. Rahul Banerjee, SDET Unit, BITS- Pilani, INDIA 48

Summary of Dierences Between L-2 Switches, Routers (L-3) and L-3 Switches
Layer-3 switches are devices which can handle all funcJonaliJes of Layer-2 Switches as well as fast (o`en based on header/tag/label switching) Layer-3 packet rouJng within but not outside the local network / internetwork; and therefore, eecJvely separate broadcast domains which end at its dierent LAN interfaces each of which carries a separate Subnet-idenJer / Subnet- address (apart from opJonal Layer-3 protocol translaJon, monitoring, security and management) Thus, in eect, we can say that:
L-3 Switches Separate broadcast domains (each of such broadcast domains which end at its dierent LAN interfaces each of which carries a separate Subnet- idenJer / Subnet-address ) L-3 Switches can carry out fast interior rouJng / packet-switching o`en based on header/tag/label switching Layer-3 Switches, opJonally, can carry out protocol translaJons (in terms of protocol-specic packet formats).
23/01/13 (c) Dr. Rahul Banerjee, SDET Unit, BITS- Pilani, INDIA 49

Inside a Layer-2 Switch


Elements of a Layer-2 Switch
Processors (Front-end Processors on Line Cards) for Frame RouJng MulJple Buers for MulJple Queues Shared I/O Bus or Ring (1st / 2nd Gen.) / Switching Fabric (3rd Gen.) I/P Line Controllers (ILC) O/P Line Controllers (OLC)

50

(c) Dr. Rahul Banerjee, BITS, Pilani, India

An Example of a Hybrid Switching Fabric


Electronic Switches Linecard 1 Linecard 2 Linecard L Group 1 Linecard 1 Linecard 2 Linecard L Group 2 Linecard 1 Linecard 2 Linecard L Group G LxM Crossbar
1 2 3 M 1 2

Fixed Lasers
1 2

Static MEMS GxG MEMS 1


M 1 2 3

Optical Electronic Receivers Switches Linecard 1 MxL Crossbar Linecard 2 Linecard L Group 1 2
1 2 3

LxM Crossbar

GxG MEMS

Linecard 1 MxL Crossbar Linecard 2 Linecard L Group 2

LxM Crossbar

3 M

GxG MEMS 3

1 2 3 M

Linecard 1 MxL Crossbar Linecard 2 Linecard L Group G

GxG MEMS M

Dr. Nick McKeown, Stanford University <modified version>

Some More Terms of Relevance


Collision Domain The set of all stations connected to a network where faithful detection of a collision can occur. A collision domain terminates at a switch port. Late Collision A failure of the network in which the collision indication arrives too late in the frame transmission to be automatically dealt with by the medium access control (MAC) Protocol. The defective frame may not be detected by all stations requiring that the application layer detect and retransmit the lost frame, resulting in greatly reduced throughput. CRC Cyclic Redundancy Check is an error-checking technique used to ensure the fidelity of received data.
52 (c) Dr. Rahul Banerjee, BITS, Pilani, India

Pervasive CompuJng with AR

January 23, 2013

(c) Dr. Rahul Banerjee, BITS Pilani, INDIA

Wearable CompuJng Elements

January 23, 2013

(c) Dr. Rahul Banerjee, BITS Pilani, INDIA

E-Fabric of a Wearable Garment

January 23, 2013

(c) Dr. Rahul Banerjee, BITS Pilani, INDIA

Wireless CommunicaJon in Wearables

January 23, 2013

(c) Dr. Rahul Banerjee, BITS Pilani, INDIA

User Interface & Sensors

January 23, 2013

(c) Dr. Rahul Banerjee, BITS Pilani, INDIA

Paradiso & Starners Shoes <1995> for Electrical Energy GeneraJon

January 23, 2013

(c) Dr. Rahul Banerjee, BITS Pilani, INDIA

You might also like