9
UNIT 2 LESSON 5 CS PRIN CIPLES

UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the

Embed Size (px)

Citation preview

Page 1: UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the

UNIT 2

LESSON 5

CS

PR

I NC

I PL E

S

Page 2: UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the

OBJECTIVES

Students will be able to:

Explain why protocols are necessary to overcome the underlying unreliability of the Internet.

Develop a protocol for reliable communication on the Internet.

Justify the need for acknowledgements and packet numbering in TCP.

Page 3: UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the

TCP

The Transmission Control Protocol (TCP) was designed to overcome the inherent unreliability of the Internet.

• A small but non-negligible percentage of packets are lost in transmission because of faults in the infrastructure of the Internet.

• In order to constrain the extent of these errors, larger messages are divided into many packets which are individually routed to their recipient.

• On receipt of a packet, the receiving computer will send an acknowledgement confirming the receipt of that packet.

• If the sending computer does not receive an acknowledgement, it will resend the packet until all packets have been acknowledged.

• Since packets may arrive out of order, additional header data is added to indicate the order in which the packets should be arranged.

• Thus, while individual packets cannot be guaranteed to arrive, eventually an entire message can be accurately reconstructed.

Page 4: UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the

JOURNAL UNIT 2 ENTRY 6

Your friend sent you a message on the Internet, but you never received it. Based on what you already know about routers and the physical Internet, list what reasons might explain this fact.

Page 5: UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the

POSSIBLE REASONS

wires are cut

interference on a radio channel

router malfunctions or cannot keep up with traffic being directed to it

the message was sent to the wrong address

Internet connectivity issues at the source (the message never reached the local network)

Page 6: UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the

INTERNET TRAFFIC

• When we communicate on the Internet, we are not just sending short text messages.

• We also use the Internet to exchange documents, videos, music, and scientific data, and these files can easily grow to enormous size.

• This would not be a problem if the Internet were perfectly reliable, but in reality, errors sometimes occur.

• Lines can be cut, routers can be overwhelmed with traffic, and interference with electric or radio signals can cause messages to become corrupted.

• The response to this problem is to split large messages into smaller pieces of information called “packets.”

Page 7: UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the

PACKETS

• It turns out that splitting up a message into packets provides many benefits.

• If a faster route opens up halfway through transmitting a large file, it is easy to reroute later packets in the transmission through that route.

• Having smaller messages to balance also makes it easy to rebalance the entire network of routers, providing more efficient usage of the entire Internet.

• Splitting up a message into smaller chunks doesn’t solve all the problems of unreliability on the Internet, and it may even add some.

• Packets can still be dropped or arrive out of order.

• Today’s challenge is to develop a protocol to make a reliable Internet, in spite of the challenges this new system poses.

Page 8: UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the

L5 ACTIVITY

The version of the Internet Simulator we will be using today has been structured to simulate the unreliability of the Internet. You’ll notice a few changes:

• You will only be allowed to send packets containing 6 characters of text; anything larger will be dropped (to simulate the fact that large messages are much more likely to have errors).

• Every message has a small chance of being dropped on each “hop” it makes between routers.

• You may construct a message with multiple packets prior to sending it.

Page 9: UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the

DEVELOP A PROTOCOL

Guidelines for Protocol:

• All communication can only be done through the Internet Simulator.

• The message sent will be at least 60 characters long and might be entirely random (i.e. there’s no way to use human intuition to reconstruct the message). The message is not known beforehand.

Note: The Teaching Tips & Tricks video mentions a 20 character long message. 60 characters is the preferred length, as it results in more packets being dropped.

The sender and receiver must be confident the full message was successfully transmitted and reconstructed.