140 likes | 254 Views
A Day in the Life of an HTTP Query. client/server paradiam. 2.DNS query. multiplexing. de multiplexing. 3.Transport protocols. HTTP & data. E. T. I. X. X. 7.Running routing protocol. Web server application. Brower application. HTTP. 1.HTTP. Socket interface. Socket interface.
E N D
A Day in the Life of an HTTP Query client/server paradiam 2.DNS query multiplexing demultiplexing 3.Transport protocols HTTP & data E T I X X 7.Running routing protocol Web server application Brower application HTTP 1.HTTP Socket interface Socket interface TCP 3.TCP IP 4.IP Ethernet 5.Ethernet X 6.IP router CS118/Spring05
Computer Networking: the overall picture • What is packet switching? • Data is cut into chunks, sent in a "store-and-forward: way • statistical multiplexing queueing delay, potential losses • why packet switching? • What’s in a packet: • header: contains all the information,and only the information that’s needed for the protocol’s functionality Efficient resource sharing Flexible delivery Packet (carries destination address) Router-1 Router-2 header data CS118/Spring05
Relative importance of transmission&propagation delay which link takes less time to get a packet to the other end? (1) 1 Mbps bandwidth, 1 ms propagation delay 1. Small packet (50bytes) • (2) 100 Mbps bandwidth, • 100 ms propagation delay 2. Large packet (10MB) CS118/Spring05
Link Utilization: One Example A sends packets to B using sliding window • bandwidth: 1Mbps • Propagation delay: 100 msec • data packet size: 1000 bytes (ACK very small) • window size: 4 packets • RTT = trans-delay(8ms) + 200ms = 208ms • utilization: (A's busy-time total-time) = (8ms 4) 208ms propagation delay B A bandwidth 8 msec CS118/Spring05
IP Suite: End Hosts vs. Routers IP IP IP Ethernet interface Ethernet interface Ethernet interface host host HTTP message HTTP HTTP TCP segment TCP TCP router router IP packet IP packet IP packet IP Ethernet interface SONET interface SONET interface This course focuses on the routers… CS118/Spring05
The HTTP protocol Use TCP transport service client initiates TCP connection (creates socket) to server server accepts TCP connection from client http messages exchanged between browser (http client) and Web server (http server) TCP connection closed http is “stateless” server maintains no information about past client requests Non-persistent http/1.0: server parses request, responds, closes TCP connection 2 RTTs to fetch object TCP connection object request/transfer many browsers open multiple parallel connections Persistent default for htp/1.1 on same TCP connection: server parses request, responds, parses new request,.. client sends requests for all referenced objects as soon as it receives base HTML. Pipelining: browser sending multiple requests before getting responses CS118/Spring05
DNS: Domain Name System cs.ucla.edu 131.179.96.15 131.179.96.15 131.179.96.15 • provides name to IP address translation • DNS name: variable length, easy for human to remember • IP address: fixed length, tied to network topology, easy for computer to process • example: send mail to john@cs.ucla.edu DNS server application IP TCP CS118/Spring05
DNS usage example • user provides the DNS name of the server • Client process sends a query to a local DNS server • each host knows a local DNS server’s IP address • the local DNS server either has the info or can get it from another DNS server • Client process receives the IP address from DNS server reply, open a TCP connection to the receiving host CS118/Spring05
name space and naming system name space • defines the set of all possible names • similar to address space • can be either flat or hierarchical • Ethernet address space is flat; DNS name space is hierarchical naming system • a collection of name-to-value bindings name resolution • given a name, return the corresponding value CS118/Spring05
Basic DNS design a hierarchical name space • starting from the root, growing downward (and side ways too) • variable depth hierarchy • each non-leaf node in the tree is a domain • any domain can have its own sub-domains, no limit on the depth of any branch • DNS name structure is completely independent from the Internet's topological structure CS118/Spring05
Reliable data delivery between two nodes • error/loss recovery by retransmission: • sequence number for each piece of data • Acknowledgment • retransmission timer • sliding window: relations between seq# and window size (Max. seq. number + 1)/2 window-size • relation between window size, throughput, and round-trip time(RTT): Window-size round-trip time • Throughput Equality achieved in the absence of errors/losses CS118/Spring05
TCP header format 31 0 16 IP header source port destination port Data sequence number acknowledgment number u a p r s F r c s s y i g k h t n n Hlen unused window size checksum urgent pointer Options (viable length) data CS118/Spring05
ON TCP • How does TCP achieve reliable data delivery? • What are the fundamental mechanisms? • How do they work? • How does TCP perform flow control? • How does TCP perform congestion control? • How does TCP estimate its RTT and set the retransmission timeout (RTO)? CS118/Spring05
IP Packet Structure usually 20 bytes usually IPv4 fragments more later error check header 4-bit Header Length 8-bit Type of Service (TOS) 4-bit Version 16-bit Total Length (Bytes) 3-bit Flags 16-bit Identification 13-bit Fragment Offset 20-byte Header 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 CS118/Spring05