TCP UDP and Reliable Data Transfer Mechanisms Flashcards

1
Q

What are the responsibilities of the transport layer service

A
  • Provide logical communication between application processes running on different hosts
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How do transport protocols run? And what does this mean?

A

They run in end systems meaning the send side breaks application messages into segments and the receiver side reassembles segments into messages to pass to the application layer.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are 2 main forms of transport layer protocol?

A

TCP and UDP (transmission control protocol) (user datagram protocol)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What does UDP provide? 4

A
  • Unreliable connectionless transport layer protocol
  • demultiplexes IP packets
  • Error checking of data
  • Has multiple applications in the host
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What kind of services is UDP used by?

A
  • Streaming media
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What famous services sometimes go on top of UDP?

A
  • SNMP
    -DHCP
  • DNS
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What happens if a UDP segment checksum field returns incorrect?

A

We dump the segment

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is TCP?

A

connection-oriented data streaming service transport layer protocol

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What does TCP provide? 4

A
  • Full duplex reliable mechanisms (go back n, selective repeat)
  • A recovery mechanism for out-of-order packets, duplicates, lost packets, corrupt packets
  • Flow and congestion control mechanisms
  • Support for multiple application processes in the same system
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

In reliable data transfer (RDT) what are two things that can accidentally trigger a resend leading to unnecessary loss?

A
  • Premature timeout
  • Delayed acknowledgement
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What are 2 RDT mechanisms?

A
  • Stop and wait
  • Sliding Window protocol
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

How does TCP initiate a connection?

A
  • 3-way handshake: send connecting signal with initial SYN message, server sends TCP SYNACK msg, to ack the SYN then client sends an ACK to server –> connection is established
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Where does the senders window start and end from for TCP?

A

First segment in window is the first that has been sent, but not yet ACKED in return, and the last element of the window will one that is ready to be sent but not yet sent.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

When sending a segment with a sequence number –> if the previous ACK had number 92 and the previous Sequence had number = 27, what will the next sequence number and returning ACK be?

A
  • Next sequence number : 92
  • Next ACK: 28

(next sequence is same as previous ACK - next ACK is one more than previous sequence)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

How does TCP close its connection?

A
  • 4 way handshake
  • client initiates with .close() command
  • FINbit is sent
  • Server responds with ACK
  • Then server sends its own FINbit and then when it receives the last ACK to its FINbit from client, connection is fully shut
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What kind of service does TCP provide and where?

A

TCP provides reliable data transfer service on top of IP connectionless service

17
Q

What 3 things does TCP do to increase reliability?

A
  • Pipelined sliding window segments so we can have a window size.
  • Cumulative acknowledgements
  • Single retransmission timer
18
Q

What are retransmissions triggered by? (2)

A
  • Timeout events
  • Duplicate acknowledgements
19
Q

How does TCP implement flow control?

A

It has a TCP socket buffer where it stores segments going to application layer, and another where segments going down to the network layer are stored too.

20
Q

What are 2 congestion control approaches that can be followed? And which is taken by TCP?

A
  • Network-assisted congestion control
  • End to end congestion control (taken by TCP)
21
Q

What is network assisted congestion control?

A
  • Routers provide feedback to end systems such as:
  • There is a single bit indicating congestion
  • Explicit rate for sender to send at
22
Q

What is end to end congestion control?

A
  • No explicit feedback from system aka from network routers
  • Congestion is inferred from end-system observed loss and delay (aka not receiving ACKS , buffers getting filled.)
23
Q

What are some causes of congestion?

A
  • If there is no space in the dedicated buffer (the new packets will either be dumped or will timeout
  • The shared output link buffers are often bottlenecks
24
Q

What happens as segments keep on getting added to the network traffic?

A

The throughput will increase initially and then the system will become congested, if this continues, throughput will reduce to 0, this happens when rate of entry is about half the system capacity (C/2)

25
Q

Why is it good to have a long timeout?

A

If timeout is long - even if you retransmit many times, it does not create critical situation.

26
Q

What can happen if timeout is too short?

A

The timer will have timed out though a packet will then have arrived shortly after - this means the next ACK number will increase even though the previous package must be resent. Basically then when the next package is resent, the package sent after it is not the one sequentially after because the ACK system has fucked up (this occurs when the timeout is too short for the RTT.

27
Q

What is a good timeout interval?

A

TimeoutInterval = EstimatedRTT + 4*DevRTT

DevRTT = (1-b) * DevRTT + b * |SampleRTT - EstimatedRTT|
typical values of b are = 0.25 (OR 0.25)

28
Q

What is Additive Increase Multiplicative Decrease (AIMD)

A
  • Additively increase window size until loss occurs
  • When loss occurs cut window size in half and then repeat
29
Q

What is TCP Slow Start (SS)?

A
  • When connection begins, increase rate exponentially until first loss event.
30
Q

What is TCP Slow Start (SS)?

A
  • When connection begins, increase rate exponentially until first loss event this occurs at the SS-threshold
31
Q

What is the other name for AIMD?

A

TCP RENO

32
Q

How does TCP Tahoe work?

A
  • Uses slow start (SS) until a predefined ss threshold (no loss occurs by ss threshold)
  • When ss_threshold is reached, starts increasing in linear way,
  • Then when first loss occurs, move the ss threshold to half of the value at first loss, and then cut window size back down to original size.
  • Start from ss again repeating above steps.

This greates a variable ss threshold.

33
Q

TCP fairness - how is bandwidth to K TCP sessions sharing the same bottleneck link with capacity R assigned?

A

k/m

34
Q

Why is TCP fair?

A

Resource repartition converges to a central point through using methods of loss reaction (cutting send window in half) and congestion avoidance (slowly increasing window through additive increase)