internet protocols fall 2003terzis/classes/cs349-fall06/lec1.pdf · – w5 (10/5) intra-domain...
TRANSCRIPT
![Page 2: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/2.jpg)
Course Description
CS449/Fall06 2
• Learn about the protocols that make the Internet work– Understand design space and tradeoffs– Compare different protocols at the same level
• Protocol examples: Ethernet, WiFi, IP, TCP, HTTP
– Examples from alternative architectures
• Learn how to write code for networked applications
![Page 3: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/3.jpg)
Text Books
CS449/Fall06 3
• Required: Computer Networks: A Systems Approach (3rd ed.) by Peterson, Davie
• Recommended: UNIX Network Programming by Richard Stevens
• Recommended: Web Protocols and Practice: HTTP/1.1, Networking Protocols, Caching and Traffic Measurements
![Page 4: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/4.jpg)
Course Times
CS449/Fall06 4
• Lectures: ThF 2:30-3:45 pm Shaffer 101
• Office Hours: ThF 1-2pm WP 417 and by appt
• TA Section: Every second week• TA Office Hours: MT 11-12, WP 425
![Page 5: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/5.jpg)
Grading Policies
CS449/Fall06 5
• Grading– Homework 10%, Projects 35% – Midterm 20%, Final 30% – Class Participation 5%– Different curves for 349/449
• NO LATE HOMEWORK OR PROJECTS ACCEPTED (really)
• Project groups DO NOT change
![Page 6: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/6.jpg)
Course Schedule
CS449/Fall06 6
– W1 (9/7) Introduction, Internet Architecture– W2 (9/14) Link Layer: Ethernet, PPP, IP – W3 (9/21) MAC– W4 (9/28) IP: Addressing, ARP/RARP, ICMP and
examples – W5 (10/5) Intra-domain routing– W6 (10/12) Inter-domain routing, IP Mobility– W7 (10/19) Review, Midterm (10/20)
![Page 7: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/7.jpg)
Course Schedule (2)
CS449/Fall06 7
– W8 (10/26) Transport layer– W9 (11/2) Congestion Control– W10 (11/09) QoS, Network Measurements– W11 (11/16) DNS, HTTP– W12 (11/23) Thanksgiving– W13 (11/30) P2P, Streaming Media– W14 (12/7) Wrap Up– Final TBA
![Page 8: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/8.jpg)
Course Projects
CS449/Fall06 8
• Three implementation projects– Learn how to write networked applications
(using the TCP/IP API)– Teams of 2-3– For the last two projects you will create a
software router/firewall that handles real traffic• http://yuba.stanford.edu/vns/
![Page 9: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/9.jpg)
Logistics
CS449/Fall06 9
• Course website– http://hinrg.cs.jhu.edu/cs349-fall06/– Check every day
• Everything goes there
• Course email list– [email protected]– To subscribe:
https://hinrg.cs.jhu.edu/mailman/listinfo/cs349/
![Page 10: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/10.jpg)
Short (P)Review
CS449/Fall06 10
• Very high-level overview of networking– Show how the World Wide Web works– Present some of the key ideas behind the
Internet architecture• Large Scale• Dealing with failures• Co-operation/Competition
![Page 11: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/11.jpg)
World Wide Web
CS449/Fall06 11
• We use it every day• Millions of websites• Webpages contain
objects– HTML, Text, images, etc– Base HTML file contains
reference to other objects
– Each object addressable by a URL
http://www.google.com/index.html
![Page 12: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/12.jpg)
Questions
CS449/Fall06 12
• How to express what we are looking for• How to find what we are looking for• How to transmit bits• How to protect against errors• How to direct bits towards the right
destination• How to share resources
![Page 13: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/13.jpg)
Solution
CS449/Fall06 13
• Divide and Conquer– Break the problem in smaller parts– Solve each part separately– Put the pieces back together
• Layering• Protocol Stack
application
transport
network
link
physical
application
transport
network
link
physical
![Page 14: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/14.jpg)
Physical Layer
CS449/Fall06 14
• Send bits between directly connected machines
• Physical Media– Twisted Pair– Coaxial Cable– Fiber Optics– Radio Link
• Bandwidth• Dedicated vs. shared link
![Page 15: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/15.jpg)
Data Link Layer
CS449/Fall06 15
• Data Link Layer functions– Framing– Error Detection &
Correction– Link sharing
• Examples– Dialup, ADSL– Cable Modems– Wireless (WiFi)
basestation
mobilehosts
router
![Page 16: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/16.jpg)
Internet: Network of Networks
CS449/Fall06 16
?Tier 1 ISP
Tier 1 ISP
Tier 1 ISP
NAP
Tier-2 ISPTier-2 ISP
Tier-2 ISP Tier-2 ISP
Tier-2 ISP
localISPlocal
ISPlocalISP
localISP
localISP Tier 3
ISP
localISP
localISP
localISP
![Page 17: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/17.jpg)
ISP Topology
CS449/Fall06 17
![Page 18: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/18.jpg)
Network Layer
CS449/Fall06 18
• Networking layer functions– Transport packets from sending to receiving hosts– Packet Switching vs. Circuit Switching
1. Send data 2. Receive data
applicationtransport
data linknetwork
physical
applicationtransport
data linknetwork
physical
![Page 19: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/19.jpg)
Forwarding vs. Routing
CS449/Fall06 19
• Forwarding– How to send packet to
the next hop towards the destination
• Routing– How to compute the next
hops
• Routing algorithms– Distance Vector (RIP)– Link State (OSPF)
packetdest nhop
IncomingLink
OutgoingLinksForwarding
Table
F D
A
ED
CB
F2
21
3
1
12
53
5
![Page 20: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/20.jpg)
Transport Layer
CS449/Fall06 20
• Packets get lost– Physical errors– Equipment failures– Congestion
• Transport layer functions– Deliver packets reliably– share resources among
all network users
applicationtransport
data linknetwork
physical
applicationtransport
data linknetwork
physical
physical
networkdata link
physical
networkdata link
physical
networkdata link
physical
networkdata link
logical end-end transport
![Page 21: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/21.jpg)
Reliable Transfer
CS449/Fall06 21
• How to recover from losses– Introduce ACKs– Timers– Stop-and-Wait
• Sender sends packet set timer
• Receiver sends ACK• If no ACK received
when timer expires sender retx
Sender Receiver
1
A:1
2TimerExpires
2
![Page 22: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/22.jpg)
Reliable Transfer (2)
CS449/Fall06 22
• Stop-and-Wait has low Utilization
• Pipelining– Senders allows multiple
yet-to-be-acked packets (window)
• Two variants– Go-Back-N– Selective repeat
Sender Receiver1
A:1
23
A:2 A:3
![Page 23: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/23.jpg)
Congestion Control
CS449/Fall06 23
• Congestion– Too many sources
sending too much data too fast for network to handle
• Results– Lost packets– Long delays
• Solutions– End-to-End – Network assisted
bottleneckrouter
capacity R
![Page 24: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/24.jpg)
Application Layer-HTTP
CS449/Fall06 24
• So far: data reliably transferred end-to-end
• HTTP: hypertext transfer protocol
• client/server model– client: browser that
requests, receives, “displays” Web objects
– server: Web server sends objects in response to requests
selene
HTTP request
HTTP request
HTTP response
HTTP response Server running
Apache Webserver
![Page 25: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/25.jpg)
Request/Response Timeline
CS449/Fall06 25
We enter URL www.google.com/index.html
1a. HTTP client initiates TCP connection to HTTP server (process) at www.google.com
2. HTTP client sends HTTP request message (containing URL). Message indicates that client wants index.html
1b. HTTP server at host www.google.com waiting for TCP connection. “accepts”connection, notifying client
3. HTTP server receives request message, forms response message containing requested object, and sends response
time
(contains text, reference to 1 jpeg image)
![Page 26: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/26.jpg)
Request/Response Timeline (cont.)
CS449/Fall06 26
time5. HTTP client receives
response message containing html file, displays html. Parsing html file, finds 1 referenced jpeg object
6. Steps 1-5 repeated for jpeg object
![Page 27: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/27.jpg)
HTTP Request Message
CS449/Fall06 27
HTTP request message:– ASCII (human-readable format)
GET /index.html HTTP/1.1Host: www.google.com User-agent: Mozilla/4.0Connection: close Accept-language:fr
(extra carriage return, line feed)
request line(GET, POST,
HEAD commands)
headerlines
Carriage return, line feed
indicates end of message
![Page 28: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/28.jpg)
HTTP Response Message
CS449/Fall06 28
HTTP/1.1 200 OK Connection closeDate: Tue, 04 Mar 2003 07:28:29 GMT Server: GWS/2.0 Content-Length: 2824 Content-Type: text/html
data data data data data ...
status line(protocol
status codestatus phrase)
headerlines
data, e.g., requestedHTML file
![Page 29: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/29.jpg)
Naming: DNS
CS449/Fall06 29
• Translate from www.google.com to 216.239.51.101
• Domain Name System:– Distributed database implemented in hierarchy of
many name servers– Application-layer protocol host, routers, name
servers to communicate to resolve names (address/name translation)
![Page 30: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/30.jpg)
Name Servers
CS449/Fall06 30
• No server has all name-to-IP address mappings
• Local name servers:– Each ISP, company has local (default) name
server– Host DNS query first goes to local name server
• Authoritative name server:– For a host: stores that host’s IP address, name– Can perform name/address translation for that
host’s name
![Page 31: Internet Protocols Fall 2003terzis/classes/cs349-fall06/lec1.pdf · – W5 (10/5) Intra-domain routing – W6 (10/12) Inter-domain routing, IP Mobility – W7 (10/19) Review, Midterm](https://reader033.vdocuments.us/reader033/viewer/2022050201/5f555ed2014c6b68435d5e7c/html5/thumbnails/31.jpg)
DNS Example
CS449/Fall06 31
root name server
requesting hostselene.cs.jhu.edu
local name server128.220.13.50
23
6
7
www.google.com
1 8
4 5
Root name server:• may not know
authoritative name server
• may know intermediate name server: who to contact to find authoritative name server
• Results are cached
authoritative name server
ns1.google.com