cos 461: computer networks · • four assignments (10% each) – 95% 3 hours, 70% 2 days late, 50%...

Post on 12-Jun-2020

4 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

COS461:ComputerNetworksSpring2011

Lectures:MW10‐10:50aminBowen222

Prof.MikeFreedman

Precepts:F10‐10:50am,11‐11:50am

Preceptors:MatveyArye,JacopoCesareo,PremGopalan

hNp://www.cs.princeton.edu/courses/archive/spr11/cos461/

WhatYouLearninThisCourse•  Knowledge:howtheInternetworks

–  IPprotocolsuite–  Internetarchitecture–  ApplicaTons(Web,DNS,P2P,…)

•  Insight:keyconceptsinnetworking–  Protocols,layering,resourceallocaTon,naming

•  Skill:networkprogramming– Manynodesaregeneral‐purposecomputers

•  Andincreasingly,evenspecial‐purposeswitchesareprogrammable!

–  Youcanprogramthenodes–  Veryeasytoinnovateanddevelopnewusesofnetwork–  Contrast:MaBellownedthetelecomnetwork,noinnovaTon

2

LearningtheMaterial:People•  Lecture(Prof.MikeFreedman)

–  SlidesavailableonlineatcourseWebsite

–  Officehours:Immediatelyfollowinglectures

•  TeachingAssistantsofficehoursTBD

•  Mainemail:cos461‐staffatlists.cs.princeton.edu–  EmailtoindividualTAswillnotbeanswered

•  MainQ&Aform:www.piazzza.com– Wewilladdallyouremailaddressestothecourse

–  GradedonclassparTcipaTon:soask*and*answer!3

LearningtheMaterial:Books•  Requiredtextbook

–  ComputerNetworks:ASystemsApproach(4thedi9on),byPetersonandDavie[Okaytousethe3rdediTon]

•  Booksonreserve– Networkingtextbooks

•  ComputerNetworking:ATop‐DownApproachFeaturingtheInternet(3rdedi9on),byKuroseandRoss

•  ComputerNetworks(4thedi9on),byTanenbaum

– Networkprogrammingreferences•  TCP/IPIllustrated,Volume1:TheProtocols,byStevens

•  UnixNetworkProgramming,Volume1:TheSocketsNetworkingAPI(3rdEdi9on),byStevens,Fenner,&Rudolf

4

GradingandSchedule•  Fourassignments(10%each)

–  95%3hours,70%2dayslate,50%>3dayslate– Onefreelatedayduringsemester– Mustcompleteallassignmentstopass

•  Twoexams(50%total)– Midtermexambeforespringbreak(25%)–  Finalexamduringexamperiod(25%)

•  ClassparTcipaTon(10%)–  Inlectureandprecept–  Intheforums

5

GraduateStudents:TwoChoices•  PickoneoftwoopTons

– Dothefourprogrammingassignments

– Or,firsttwoassignments,plusresearchproject

•  Researchprojects– Networking‐relatedresearchproblem

– Musthaveasystemsprogrammingcomponent– Talktome

6

Policies:WriteYourOwnCodeProgramminginanindividualcreaTveprocess.Whilethinkingaboutaproblem,discussionswithfriendsareencouraged.However,whentheTmecomestowritecodethatsolvestheproblem,theprogrammustbeyourownwork.

IfyouhaveaquesTonabouthowtousesomefeatureofC,UNIX,etc.,youcancertainlyaskyourfriendsortheTA,butdonot,underanycircumstances,copyanotherperson'sprogram.

Lerngsomeonecopyyourprogramorusingsomeoneelse'scodeinanyformisaviola7onofacademicregula7ons.

7

NetworkingisRelevant

8

9

Informa7onwants to be free because it has becomesocheaptodistribute,copy,andrecombine...Itwantsto be expensive because it can be immeasurablyvaluabletotherecipient. (1985)

http://www.google.com/transparencyreport/traffic/

Themonolithicview

14

1

2

3 4

5

6 7

Client Browser

Web server

THEINTERNET

!!!!

Why“Internet”•  Networkofnetworks•  StandardizedformatandprotocolsforspeakingbetweenHETEROGENOUSnetworks

15

Why“Internet”•  Networkofnetworks•  StandardizedformatandprotocolsforspeakingbetweenHETEROGENOUSnetworks

16

Themonolithicview

17

1

2

3 4

5

6 7

Client Browser

Web server

THEINTERNET

!!!!

Anetworkof“AutonomousSystems”

18

3 4

5

7

Client Browser

Web server

6

1

2

• Howdoyouname?• Howdoyoufindaname?

Announcingatrafficroute

19

3 4

5

7

Client Browser

Web server

6

1

2

“EgyptisinthisdirecTon”

“RouTng”traffictoadesTnaTon

20

3 4

5

7

Client Browser

Web server

6

1

2

Withdrawingatrafficroute

21

3 4

5

7

Client Browser

Web server

6

1

2

“EgyptisnotinthisdirecTon”

???

KeyConceptsinNetworking•  Protocols

– Speakingthesamelanguage– SyntaxandsemanTcs

•  Layering– Standingontheshouldersofgiants– Akeytomanagingcomplexity

•  ResourceallocaTon– DividingscareresourcesamongcompeTngparTes– Memory,linkbandwidth,wirelessspectrum,paths,

•  Naming– Whattocallcomputers,services,protocols,…

24

KeyConceptsinNetworking•  Protocols

– Speakingthesamelanguage– SyntaxandsemanTcs

25

1977 1998 1969

AllspeakIPv4“InternetProtocolversion4”

Protocoldesignisabouttradeoffs•  Howshouldhostsandrouterscommunicate?

– Standardprotocol– Fast:Machinereadableinhardwareatlinerates

•  Browsers,webservers,andproxies?– Canbeslower:sowwarereadable– Humanreadable– Extensibleandforward‐compaTble– Noteverybodymightbefamiliarwithextensions

26

IPv4Packet

27

4-bit Version

4-bit Header Length

8-bit Type of Service (TOS) 16-bit Total Length (Bytes)

16-bit Identification 3-bit Flags 13-bit Fragment Offset

8-bit Time to Live (TTL)

8-bit Protocol 16-bit Header Checksum

32-bit Source IP Address

32-bit Destination IP Address

Options (if any)

Payload

Example:HyperTextTransferProtocol

28

GET /courses/archive/spr09/cos461/ HTTP/1.1 Host: www.cs.princeton.edu User-Agent: Mozilla/4.03 CRLF

HTTP/1.1 200 OK Date: Mon, 2 Feb 2009 13:09:03 GMT Server: Netscape-Enterprise/3.5.1 Last-Modified: Mon, 42 Feb 2009 11:12:23 GMT Content-Length: 21 CRLF Site under construction

Request

Response

KeyConceptsinNetworking•  Protocols

– Speakingthesamelanguage– SyntaxandsemanTcs

•  Layering– Standingontheshouldersofgiants– Akeytomanagingcomplexity

29

Layering=FuncTonalAbstracTon•  Sub‐dividetheproblem

– Eachlayerreliesonservicesfromlayerbelow– Eachlayerexportsservicestolayerabove

•  InterfacebetweenlayersdefinesinteracTon– HidesimplementaTondetails– Layerscanchangewithoutdisturbingotherlayers

30 Link hardware

Host-to-host connectivity

Application-to-application channels

Application

TheInternetProtocolSuite

31

UDP TCP

Data Link

Physical

Applications

The Hourglass Model

Waist

The waist facilitates interoperability

FTP HTTP TFTP NV

TCP UDP

IP

NET1 NET2 NETn …

LayerEncapsulaToninHTTP

32

Get index.html

Connection ID

Source/Destination

Link Address

User A User B

Link hardware

Host-to-host connectivity

App-to-app channels

Application

IPSuite:EndHostsvs.Routers

33

HTTP

TCP

IP

Ethernet interface

HTTP

TCP

IP

Ethernet interface

IP IP

Ethernet interface

Ethernet interface

SONET interface

SONET interface

host host

router router

HTTP message

TCP segment

IP packet IP packet IP packet

Conclusions•  Internetisanetworkofnetworks

– Howhostsandnetworksnameoneanother,findoneanother,andtalkwithoneanother

•  Keyconceptsinnetworking– Protocols,layers,resourceallocaTon,andnaming

•  Nextlecture:– HowdoesYouTubeandNeylixserveyouvideos?– E.g.,HTTP,DNS,andcontentdistribuTonnetworks

•  Nextweek:– Backtothe1960s

34

top related