π K-buckets in Kademlia explained (10 MCQs)
π From Data Communication and Networks β’ 29. Peer to Peer Paradigm β’ 10 questions available
What is K-buckets in Kademlia explained?
K-buckets in Kademlia are lists that store up to k nodes for each possible XOR distance range, prioritizing recently seen nodes and automatically replacing stale entries to maintain an accurate and responsive view of nearby peers.
π All K-buckets in Kademlia explained MCQs
Q1. In the RTP packet header, what is the size of the Version (Ver) field?
π Explanation: The Version field occupies exactly two bits, allowing values 0β3. RTP currently defines version 2, which fits within this 2βbit space. The small size keeps the header compact while still permitting future version extensions. Hence, the correct answer is the 2βbit option.
Q2. If the Padding (P) bit is set to 1, how must the receiver compute the actual RTP payload length?
π Explanation: When P=1, the last byte of the packet indicates how many padding bytes were added. The receiver subtracts this value from the total UDP length (minus the RTP header) to obtain the true payload length. This subtraction yields the correct payload size.
Q3. When the Extension (X) bit equals 1, what additional structure appears in the RTP header?
π Explanation: Setting X=1 signals that an optional extension header is present immediately after the fixed RTP header. This extension can carry extra information defined by the application. No other fields are altered, making the extension header the sole addition when X is set.
Q4. How does setting the Marker (M) bit affect stream synchronization compared to leaving it cleared?
π Explanation: The Marker bit is used by many codecs to mark significant events, such as the end of a video frame. When set, the decoder can recognize frame boundaries, improving synchronization and reducing jitter. Leaving it cleared provides no such cue, potentially causing misalignment.
Q5. If the Contributor Count field is set to its maximum value, how does the RTP header size change?
π Explanation: A maximum contributor count of 15 means fifteen 32βbit CSRC identifiers are appended. Each CSRC adds 4 bytes, so the header expands by bytes. No other fields change size, making the 60βbyte increase the correct effect.
Q6. In what way does the Timestamp field assist a jitter buffer in handling variable network delay?
π Explanation: The Timestamp conveys the sampling instant of the first byte in the payload. A jitter buffer uses this value to schedule playback at the correct moment, compensating for network delay variability. By aligning packets according to their timestamps, smooth media delivery is achieved.
Q7. When transmitting encrypted RTP payloads that require padding, which fields must be configured and how does the receiver recover the original payload length?
π Explanation: For encrypted data, padding is added and indicated by setting P=1. The last byte of the packet contains the padding length. The receiver subtracts this value from the total UDP length (after removing the RTP header) to obtain the true payload size, ensuring correct decryption.
Q8. If the 16βbit Sequence Number wraps after packets, what is the consequence for detecting packet loss?
π Explanation: When the sequence number reaches its maximum () and wraps to zero, the receiver must interpret numbers modulo . By comparing the difference between successive numbers, it can still identify gaps that indicate packet loss, despite the wraparound.
Q9. How does RTP differ from TCP regarding outβofβorder delivery, and which RTP header field enables the receiver to reorder packets?
π Explanation: RTP does not enforce reliable, inβorder delivery; packets may arrive out of sequence. The 16βbit Sequence Number field provides a logical order, enabling the receiver to reorder packets before decoding. TCP, by contrast, ensures ordered delivery at the transport layer.
Q10. What is the relationship between the Payload Type field and codec negotiation in RTP streams?
π Explanation: During session setup, the SDP exchange assigns specific Payload Type numbers to codecs. The RTP header then carries this numeric value, allowing the receiver to select the correct codec for decoding. Thus, the Payload Type serves as a reference to the negotiated codec, not the codec itself.