TCP/UDP Flashcards
(27 cards)
What services do TCP provide?
message fragmentation and reassembly, guarantees accurate delivery, maintains conversational context, specifies process at destination, congestion and flow control
Why fragment messages?
error correction and speed
error correction when messages are fragmented
is part of message is lost/garbled, only have to resend affected packet(s)
speed when messages are fragmented
store-and-forward delay is minimized, not possible if whole message is sent at once
store-and-forward
A can send packet 1 to B while receiving packet 2 from sender
What goes into guaranteed delivery?
- sender remembers which packets it sent, 2. error detection by receiver, 3. receiver acknowledges each packet received, 4. if ack not received within specified timeout interval, sender resends packet
What detects IP packet corruption?
checksum
TCP packets specify a source and destination _____.
port number
What is a port number used to determine?
which process (program) will receive the message
In conversational context, two machines must _____, _____, and _____.
establish a connection before they can exchange data; agree on a session ID before sending first message; agree that the convo is over
Each message sent between two machines includes _____.
the session ID
If a router is overworked, _____ and _____.
its queues fill up; it drops additional packets
Because TCP provides guaranteed delivery through ack, source _____ during TCP congestion
resends packets (which exacerbates congestion)
exponential backoff
quickly decrease rate of packet sends if packet acks are slow (not received within timeout interval)
how to control TCP congestion
start slow using a low rate of packet sends, slowly increase rate as long as acks are regularly received
Flow control is similar to congestion control, but with this key difference:
It’s not due to network interference.
Why would you need flow control?
destination host’s own traffic is too much, destination unable to receive so fast
TCP does these two things that IP does not:
helps manage traffic on the internet, guarantees packet delivery on the internet
TCP does not do this, while IP does:
provide unique address scheme for the internet
Neither TCP nor IP guarantee what?
speed of packet delivery
UDP is an…
alternative to TCP.
Like TCP, UDP…
builds on top of IP but provides less.
UDP is better for _____.
real-time applications (video, audio, etc.)
UDP includes…
checksum for error detection, port numbers