TCP/IP Flashcards
In what components of a network does transport protocols run?
In end-system. The edges of the networks, the hosts
What does the end user need from the transport layer?
- connection management
- reliability (guaranteed info. arrival)
- timing e.g. for streamed coms.
What services to the internet transport protocols offer the application?
TCP:
- setup (connections)
- reliable transport
-flow control
-action upon congestion
TCP does not provide timing or bandwidth guarantees.
UDP:
- best effort. Relies on IP transport capabilities which are essentially none.
-connectionless
In TCP demultiplexing, how do we direct the message to the correct socket?
We use the src and destination IPs and port number to identify the socket. I.e the 4-tuple.
How do we demultiplex a UPD datagram at ?
Simply looking at destination IP and port in header and directing packet to that socket.
Datagrams with same dest.port # but different source IP addresses and/or source port numbers will be directed to the same socket
What is the stop and wait technique: Positive acknowledgement with retransmission?
Receiver sends acknowledgement when data arrives
Sender starts timer whenever transmitting
Sender retransmits if timer expires before acknowledgement arrives
What are the disadvatanges with stop and wait?
The bandwithd utilization SO LOW. We are wasting capacity of link.
What is the sliding window technique used for?
It is used to prevent the low bandwidth utilisation that comes with Stop&Wait. With sliding window, several unACKed segments can be in transmission, waiting for acknowledgement instead of just 1.
How are timeouts set in TCP?
- By monitoring the RTT of sent packets. If this is increased, we can dynamically increase the timout to adapt to slower networks.
- EWMA, calculates an average but gives more weight to recent RTT data.
Explain the Fast Retransmit functionality in TCP?
- When a receiver has gotten a segment out of order or is missing a segment it can send duplicate ACKs indicating which packet is missing.
- If sender gets back 3 duplicate ACKS, it know it should drop everything and retransmit the missing packet, so we can recover for the packet loss without resending all the data.
What is the purpose of the RcvWindow field in the TCP segment header?
part of TCP flow control. It tells the sender the size of the current receive window so that it can adjust how many unACKd data it can continue to transmit.
Define network congestion
Network congestion is a critical issue that arises when the demand for available network resources, such as bandwidth and processing capacity, exceeds what the network can provide.
What are the consequences of Network congestion?
- Packet loss due to overflowed buffer space in routers/switches.
- Increased latency
- reduced throughtput
- degraded UX
What is the difference between TCP flow och congestion control (hint: scope)
flow control focuses on making sure sender and receiver operate at same rate to not overflow receiver. Balancing sender receiver capacity.
Congestion control is a core network issue and not about the capacity of an induvidual system or edge pair.§
What are the goals of congestion control?
- Fair resource sharing. Fair distribution of network resources amongst its users.
- Preventing network collpase, to prevent deteriorating network performance
- ## To be able to uphold a quality of service
What is TCP CWND?
The heart of TCP congestion control. represents the maximum number of unacknowledged packets that a sender can have in transit at any given time. It essentially determines how much data can be in flight across the network.
What parameters form basis of TCP congestion control?
- CWND
- RWND
- ACKs
- Sender dynamic capabilities
What does the CWND consist of:
Consists of 2 components: “Bytes in Flight” (BIF), representing unacknowledged data in transit, and the “Receiver Window” (rwnd), indicating the receiver’s buffer space.
How is the throughput in bytes/sec calculated for a TCP connection? and what do the variables stand for?
w = # of segments sent within one RTT.
MSS = Maximum segment Size. self-explanatory
RTT= Round trip time.
(w * MSS) / RTT
What does this calculate?
w * MSS:
the total amount of data transmitted in one RTT
What is an indicator of congestion?
duplicate ACKs!
What happens with CWND when congestion is high vs low?
it grows and shrinks
How does the CWND grow (and shrink)
exponentially and arithmetically
Describe multiplicative update and decrease!
Congestion:
CWND = CWND/2
No Congestion:
CWND = CWND*2
- it is fast, but unfair
- When congestion is detected, TCP connections engage in multiplicative decrease, where they significantly reduce their sending rates by halving the congestion window size.