in Computer Networks
12,098 views
30 votes
30 votes

Which one of the following uses UDP as the transport protocol?

  1. HTTP
  2. Telnet
  3. DNS
  4. SMTP
in Computer Networks
12.1k views

1 comment

DNS uses both TCP and UDP for valid reasons. UDP messages are not larger than 512 Bytes and are trucncted when greater than this size. So DNS uses TCP for Zone transfer and UDP for name queries either regular (primary) or reverse. UDP can be used to exchange small information whereas TCP must be used to exchange information larger than 512 bytes. If a client doesn’t get response from DNS it must retransmit the data using TCP after 3-5 seconds of interval.

We all know that there shouldn’t be any inconsistency in DNS zones – to make this happen DNS always transfer Zone data using TCP because TCP is reliable and make sure zone data is consistent by transfering the full zone to other DNS servers who has requested the data.

Source: http://blogs.msmvps.com/systmprog/2006/12/22/dns-works-on-both-tcp-and-udp/

11
11

5 Answers

35 votes
35 votes
Best answer
The answer is C.

Where quick response is needed, there UDP is preferred.
selected by

4 Comments

https://support.microsoft.com/en-us/help/556000 article says DNS uses TCP for zone data transfer and UDP for name queries. So is DNS, the correct answer to this question?

5
5
Yes. DNS is correct. Here the context is name queries hence DNS would use UDP. If explicitly mentioned about zone transfer then one can go for TCP.
5
5
DNS uses UDP when the size of the response if less than 512 bytes. If it's more than that, then TCP connection is used.
8
8
  •  DNS requests are generally very small and fit well within UDP segments.
  • UDP is not reliable, but reliability can added on application layer. An application can use UDP and can be reliable by using a timeout and resend at the application layer.

https://www.geeksforgeeks.org/why-does-dns-use-udp-and-not-tcp/ 

1
1
23 votes
23 votes

Refer Table: 

Option C

edited by
9 votes
9 votes

Answer is (C)

TCP-Connection Oriented,Highly reliable,Slower.

UDP-Connectionless,Unreliable,Faster than TCP.

A)HTTP communication usually takes place over TCP/IP connections. The default port is TCP 80, but other ports can be used.HTTP only presumes a reliable transport; any protocol that provides such guarantees can be used;

B)Telnet is a  client-server protocol, based on a reliable connection oriented transport. Typically, this protocol is used to establish a connection to TCP port number 23.

D)SMTP is a mail transport protocol, and in mail every single packet is important. If you lose several packets in the middle of the message the recipient might not even receive the message and if they do they might be missing key information. This makes TCP more appropriate because it ensure that every packet is delivered.

C)DNS primarily uses the User Datagram Protocol (UDP) on port number 53 to serve requests. DNS queries consist of a single UDP request from the client followed by a single UDP reply from the server. When the length of the answer exceeds 512 bytes, larger UDP packets are used. Otherwise, the query is sent again using the Transmission Control Protocol (TCP).

https://stackoverflow.com/questions/323351/does-http-use-udp

https://en.wikipedia.org/wiki/Telnet

https://stackoverflow.com/questions/16809214/is-smtp-based-on-tcp-or-udp

https://en.wikipedia.org/wiki/Domain_Name_System

 

7 votes
7 votes
DNS uses the UDP at the transport layer with port number 53.

1 comment

it uses tcp also .....
1
1
Answer:

Related questions