SlideShare a Scribd company logo
11 
User Datagram 
Protocol 
(UDP)
UDP is a communications protocol that offers a limited amount of service 
when messages are exchanged between computers in a network that 
uses the Internet Protocol (IP). UDP is an alternative to the 
Transmission Control Protocol (TCP) and, together with IP, is sometimes 
referred to as UDP/IP. Like the Transmission Control Protocol, UDP uses 
the Internet Protocol to actually get a data unit (called a datagram) from 
one computer to another. 
22 
Unlike TCP, however, UDP does not provide the service of 
dividing a message into packets (datagrams) and reassembling it at the 
other end. Specifically, UDP doesn't provide sequencing of the packets 
that the data arrives in. This means that the application program that 
uses UDP must be able to make sure that the entire message has arrived 
and is in the right order. Network applications that want to save 
processing time because they have very small data units to exchange 
(and therefore very little message reassembling to do) may prefer UDP 
to TCP. The Trivial File Transfer Protocol (TFTP) uses UDP instead of 
TCP.
The User Datagram Protocol (UDP) is one of the 
core members of the Internet protocol suite (the set 
of network protocols used for the Internet). With 
UDP, computer applications can send messages, in 
this case referred to as datagrams , to other hosts 
on an Internet Protocol (IP) network without prior 
communications to set up special transmission 
channels or data paths. The protocol was designed 
by David P. Reed in 1980 and formally defined in 
RFC 768. 
33
4
5
UDP is located between the application layer 
and the IP layer, and serves as the intermediary 
between the application programs and the 
network operations. 
66
77 
Figure 14.1 Position of UDP in the TCP/IP protocol suite
Applications 
Numerous key Internet applications use UDP, including: the 
Domain Name System (DNS), where queries must be fast and 
only consist of a single request followed by a single reply 
packet, the Simple Network Management Protocol (SNMP), 
the Routing Information Protocol (RIP)[2] and the Dynamic Host 
Configuration Protocol (DHCP). 
Voice and video traffic is generally transmitted using UDP 
many businesses are finding that a recent increase in UDP 
traffic from these real-time applications is hindering the 
performance of applications using TCP, such as point of sale, 
accounting, and database systems. When TCP detects packet 
loss, 
88
99 
USER DATAGRAM 
UDP packets, called user datagrams, have a 
fixed-size header of 8 bytes.
Example 
The following is a dump of a UDP header in 
hexadecimal format. 
1100 
a. What is the source port number? 
b. What is the destination port number? 
c. What is the total length of the user datagram? 
d. What is the length of the data? 
f. What is the client process?
Solution 
a. The source port number is the first four 
hexadecimal digits (CB84)16 or 52100. 
b. The destination port number is the second four 
hexadecimal digits (000D)16 or 13. 
c. The third four hexadecimal digits (001C)16 define 
the length of the whole UDP packet as 28 bytes. 
d. The length of the data is the length of the whole 
packet 
minus the length of the header, or 28 – 8 = 20 
bytes. 
f. The client process is the Daytime (see Table 14.1). 
1111
1122
1133 
Encapsulation and decapsulation
1144 
Queues in UDP
Multiplexing and demultiplexing 
TCP/IIPP PPrroottooccooll SSuuiittee 1155
1166 
UDP is an example of the 
Note 
connectionless simple protocol with the 
exception of an optional checksum 
added to packets for error detection.
A client-server application such as DNS uses the 
services of UDP because a client needs to send a 
short request to a server and to receive a quick 
response from it. The request and response can each 
fit in one user datagram. Since only one message is 
exchanged in each direction, the connectionless 
feature is not an issue; the client or server does not 
worry that messages are delivered out of order. 
1177 
Why UDP?
A client-server application such as SMTP which is 
used in electronic mail, cannot use the services of 
UDP because a user can send a long e-mail 
message, which may include multimedia (images, 
audio, or video). If the application uses UDP and the 
message does not fit in one single user datagram, the 
message must be split by the application into 
different user datagrams. Here the connectionless 
service may create problems. The user datagrams 
may arrive and be delivered to the receiver 
application out of order. The receiver application may 
not be able to reorder the pieces. This means the 
connectionless service has a disadvantage for an 
application program that sends long messages. 
1188
Assume we are downloading a very large text file 
from the Internet. We definitely need to use a 
transport layer that provides reliable service. We 
don’t want part of the file to be missing or corrupted 
when we open the file. The delay created between 
the delivery of the parts are not an overriding 
concern for us; we wait until the whole file is 
composed before looking at it. In this case, UDP is 
not a suitable transport layer. 
1199
2200 
UDP PACKAGE 
To show how UDP handles the sending and 
receiving of UDP packets, we present a 
simple version of the UDP package. 
We can say that the UDP package 
involves five components: a control-block 
table, input queues, a control-block module, 
an input module, and an output module.
UDP design 
TCP/IIPP PPrroottooccooll SSuuiittee 2211
2222
2233
2244
2255
The first activity is the arrival of a user datagram with destination port number 
52,012. The input module searches for this port number and finds it. Queue 
number 38 has been assigned to this port, which means that the port has been 
previously used. The input module sends the data to queue 38. The control-block 
table does not change. 
After a few seconds, a process starts. It asks the operating system for a port 
number and is granted port number 52,014. Now the process sends its ID 
(4,978) and the port number to the control-block module to create an entry in 
the table. The module takes the first FREE entry and inserts the information 
received. The module does not allocate a queue at this moment because no 
user datagrams have arrived for this destination (see Table 14.6). 
A user datagram now arrives for port 52,011. The input module checks 
the table and finds that no queue has been allocated for this 
destination since this is the first time a user datagram has arrived for 
this destination. The module creates a queue and gives it a number 
(43). See Table 14.7. 
After a few seconds, a user datagram arrives for port 52,222. The 
input module checks the table and cannot find an entry for this 
destination. The user datagram is dropped and a request is made 
to ICMP to send an unreachable port message to the source. 
2266
2277
2288 
Reliability and congestion control solutions 
Lacking reliability, UDP applications must generally be willing 
to accept some loss, errors or duplication. Some applications, 
such as TFTP, may add rudimentary reliability mechanisms 
into the application layer as needed. 
Most often, UDP applications do not employ reliability 
mechanisms and may even be hindered by them. Streaming 
media, real-time multiplayer games and voice over IP (VoIP) 
are examples of applications that often use UDP. In these 
particular applications, loss of packets is not usually a fatal 
problem. If an application requires a high degree of reliability, 
a protocol such as the Transmission Control Protocol may be 
used instead.
2299
3300 
Thanvi

More Related Content

What's hot

Transport layer services
Transport layer servicesTransport layer services
Transport layer services
Melvin Cabatuan
 
TCP vs UDP / Sumiet23
TCP vs UDP / Sumiet23TCP vs UDP / Sumiet23
TCP vs UDP / Sumiet23
Sumiet Talekar
 
Routing protocols
Routing protocolsRouting protocols
Routing protocols
N.Jagadish Kumar
 
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESSComputer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Dr. SELVAGANESAN S
 
Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)
k33a
 
Transport layer
Transport layerTransport layer
Transport layer
reshmadayma
 
IPv4
IPv4IPv4
Routing algorithm
Routing algorithmRouting algorithm
Routing algorithm
Bushra M
 
TCP/IP and UDP protocols
TCP/IP and UDP protocolsTCP/IP and UDP protocols
TCP/IP and UDP protocols
Dawood Faheem Abbasi
 
UDP - User Datagram Protocol
UDP - User Datagram ProtocolUDP - User Datagram Protocol
UDP - User Datagram Protocol
Peter R. Egli
 
Transport layer
Transport layer Transport layer
Transport layer
Mukesh Chinta
 
icmp , igmp
icmp , igmpicmp , igmp
icmp , igmp
AKSHIT KOHLI
 
Congestion on computer network
Congestion on computer networkCongestion on computer network
Congestion on computer networkDisi Dc
 
Agent discovery& registration
Agent discovery& registrationAgent discovery& registration
Agent discovery& registration
rajisri2
 
TCP-IP Reference Model
TCP-IP Reference ModelTCP-IP Reference Model
TCP-IP Reference Model
Mukesh Tekwani
 
Distance Vector & Link state Routing Algorithm
Distance Vector & Link state Routing AlgorithmDistance Vector & Link state Routing Algorithm
Distance Vector & Link state Routing Algorithm
MOHIT AGARWAL
 
Routing algorithms
Routing algorithmsRouting algorithms
Routing algorithms
Parameswaran Selvakumar
 
Computer network switching
Computer network switchingComputer network switching
Computer network switching
Shivani Godha
 

What's hot (20)

Transport layer services
Transport layer servicesTransport layer services
Transport layer services
 
TCP vs UDP / Sumiet23
TCP vs UDP / Sumiet23TCP vs UDP / Sumiet23
TCP vs UDP / Sumiet23
 
Routing protocols
Routing protocolsRouting protocols
Routing protocols
 
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESSComputer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
 
TCP IP Addressing
TCP IP AddressingTCP IP Addressing
TCP IP Addressing
 
Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)
 
Icmp
IcmpIcmp
Icmp
 
Transport layer
Transport layerTransport layer
Transport layer
 
IPv4
IPv4IPv4
IPv4
 
Routing algorithm
Routing algorithmRouting algorithm
Routing algorithm
 
TCP/IP and UDP protocols
TCP/IP and UDP protocolsTCP/IP and UDP protocols
TCP/IP and UDP protocols
 
UDP - User Datagram Protocol
UDP - User Datagram ProtocolUDP - User Datagram Protocol
UDP - User Datagram Protocol
 
Transport layer
Transport layer Transport layer
Transport layer
 
icmp , igmp
icmp , igmpicmp , igmp
icmp , igmp
 
Congestion on computer network
Congestion on computer networkCongestion on computer network
Congestion on computer network
 
Agent discovery& registration
Agent discovery& registrationAgent discovery& registration
Agent discovery& registration
 
TCP-IP Reference Model
TCP-IP Reference ModelTCP-IP Reference Model
TCP-IP Reference Model
 
Distance Vector & Link state Routing Algorithm
Distance Vector & Link state Routing AlgorithmDistance Vector & Link state Routing Algorithm
Distance Vector & Link state Routing Algorithm
 
Routing algorithms
Routing algorithmsRouting algorithms
Routing algorithms
 
Computer network switching
Computer network switchingComputer network switching
Computer network switching
 

Viewers also liked

Unit III IPV6 UDP
Unit III IPV6 UDPUnit III IPV6 UDP
Unit III IPV6 UDPsangusajjan
 
Chapter 3 : User Datagram Protocol (UDP)
Chapter 3 : User Datagram Protocol (UDP)Chapter 3 : User Datagram Protocol (UDP)
Chapter 3 : User Datagram Protocol (UDP)
Ministry of Higher Education
 
Analysis of Link State Resource Reservation Protocol for Congestion Managemen...
Analysis of Link State Resource Reservation Protocol for Congestion Managemen...Analysis of Link State Resource Reservation Protocol for Congestion Managemen...
Analysis of Link State Resource Reservation Protocol for Congestion Managemen...
ijgca
 
Rfc768
Rfc768Rfc768
Rfc768
Sriram Raj
 
data controls in asp.net
data controls in asp.netdata controls in asp.net
data controls in asp.netsubakrish
 
Protocolos
ProtocolosProtocolos
Protocolos
chapassuca
 
ICMP
ICMPICMP
Tcp udp
Tcp udpTcp udp
Tcp udp
Programmer
 
Fellow Developers, Let's Discover Your Superpower
Fellow Developers, Let's Discover Your SuperpowerFellow Developers, Let's Discover Your Superpower
Fellow Developers, Let's Discover Your Superpower
Riza Fahmi
 
Mobile Programming - 3 UDP
Mobile Programming - 3 UDPMobile Programming - 3 UDP
Mobile Programming - 3 UDP
Riza Fahmi
 
Iphone programming: Objective c
Iphone programming: Objective cIphone programming: Objective c
Iphone programming: Objective c
Kenny Nguyen
 
Chap 12 tcp
Chap 12 tcpChap 12 tcp
Chap 12 tcp
Sparsh Samir
 
Easy Steps to implement UDP Server and Client Sockets
Easy Steps to implement UDP Server and Client SocketsEasy Steps to implement UDP Server and Client Sockets
Easy Steps to implement UDP Server and Client Sockets
babak danyal
 
Objective-Cひとめぐり
Objective-CひとめぐりObjective-Cひとめぐり
Objective-Cひとめぐり
Kenji Kinukawa
 
Tcp Udp Icmp And The Transport Layer
Tcp Udp Icmp And The Transport LayerTcp Udp Icmp And The Transport Layer
Tcp Udp Icmp And The Transport Layer
tmavroidis
 
Introduction to Objective - C
Introduction to Objective - CIntroduction to Objective - C
Introduction to Objective - C
Jussi Pohjolainen
 
RARP, BOOTP, DHCP and PXE Protocols
RARP, BOOTP, DHCP and PXE ProtocolsRARP, BOOTP, DHCP and PXE Protocols
RARP, BOOTP, DHCP and PXE Protocols
Peter R. Egli
 

Viewers also liked (20)

Unit III IPV6 UDP
Unit III IPV6 UDPUnit III IPV6 UDP
Unit III IPV6 UDP
 
Chapter 3 : User Datagram Protocol (UDP)
Chapter 3 : User Datagram Protocol (UDP)Chapter 3 : User Datagram Protocol (UDP)
Chapter 3 : User Datagram Protocol (UDP)
 
Analysis of Link State Resource Reservation Protocol for Congestion Managemen...
Analysis of Link State Resource Reservation Protocol for Congestion Managemen...Analysis of Link State Resource Reservation Protocol for Congestion Managemen...
Analysis of Link State Resource Reservation Protocol for Congestion Managemen...
 
Rfc768
Rfc768Rfc768
Rfc768
 
data controls in asp.net
data controls in asp.netdata controls in asp.net
data controls in asp.net
 
Protocolos
ProtocolosProtocolos
Protocolos
 
ICMP
ICMPICMP
ICMP
 
Nnnnnn
NnnnnnNnnnnn
Nnnnnn
 
Tcp udp
Tcp udpTcp udp
Tcp udp
 
Tcp Udp
Tcp UdpTcp Udp
Tcp Udp
 
Fellow Developers, Let's Discover Your Superpower
Fellow Developers, Let's Discover Your SuperpowerFellow Developers, Let's Discover Your Superpower
Fellow Developers, Let's Discover Your Superpower
 
Mobile Programming - 3 UDP
Mobile Programming - 3 UDPMobile Programming - 3 UDP
Mobile Programming - 3 UDP
 
Iphone programming: Objective c
Iphone programming: Objective cIphone programming: Objective c
Iphone programming: Objective c
 
Chap 12 tcp
Chap 12 tcpChap 12 tcp
Chap 12 tcp
 
Easy Steps to implement UDP Server and Client Sockets
Easy Steps to implement UDP Server and Client SocketsEasy Steps to implement UDP Server and Client Sockets
Easy Steps to implement UDP Server and Client Sockets
 
Ch11
Ch11Ch11
Ch11
 
Objective-Cひとめぐり
Objective-CひとめぐりObjective-Cひとめぐり
Objective-Cひとめぐり
 
Tcp Udp Icmp And The Transport Layer
Tcp Udp Icmp And The Transport LayerTcp Udp Icmp And The Transport Layer
Tcp Udp Icmp And The Transport Layer
 
Introduction to Objective - C
Introduction to Objective - CIntroduction to Objective - C
Introduction to Objective - C
 
RARP, BOOTP, DHCP and PXE Protocols
RARP, BOOTP, DHCP and PXE ProtocolsRARP, BOOTP, DHCP and PXE Protocols
RARP, BOOTP, DHCP and PXE Protocols
 

Similar to User Datagram protocol For Msc CS

UDP and TCP header.ppt
UDP and TCP header.pptUDP and TCP header.ppt
UDP and TCP header.ppt
nehayarrapothu
 
07 coms 525 tcpip - udp
07    coms 525 tcpip - udp07    coms 525 tcpip - udp
07 coms 525 tcpip - udp
Palanivel Kuppusamy
 
Computer Communication Networks- TRANSPORT LAYER PROTOCOLS
Computer Communication Networks- TRANSPORT LAYER PROTOCOLSComputer Communication Networks- TRANSPORT LAYER PROTOCOLS
Computer Communication Networks- TRANSPORT LAYER PROTOCOLS
Krishna Nanda
 
unit 3 ns.ppt
unit 3 ns.pptunit 3 ns.ppt
unit 3 ns.ppt
Kamesh486870
 
Tcp and udp
Tcp and udpTcp and udp
Tcp and udp
Ahmad Khalid Nasrat
 
CN Activity 3.pptx
CN Activity 3.pptxCN Activity 3.pptx
CN Activity 3.pptx
sample57
 
Transport Layer Numericals
Transport Layer NumericalsTransport Layer Numericals
Transport Layer Numericals
Manisha Keim
 
Chapter Five - Transport Layer.pptx
Chapter Five - Transport Layer.pptxChapter Five - Transport Layer.pptx
Chapter Five - Transport Layer.pptx
GirT2
 
UNit-4 Transport Layer and its protocols.pdf
UNit-4 Transport Layer  and its protocols.pdfUNit-4 Transport Layer  and its protocols.pdf
UNit-4 Transport Layer and its protocols.pdf
ManimegalaM3
 
TCP AND UDP
TCP AND UDP TCP AND UDP
Introduction of tcp, ip & udp
Introduction of tcp, ip & udpIntroduction of tcp, ip & udp
Introduction of tcp, ip & udprahul kundu
 
UDP and TCP Protocol & Encrytion and its algorithm
UDP and TCP Protocol & Encrytion and its algorithmUDP and TCP Protocol & Encrytion and its algorithm
UDP and TCP Protocol & Encrytion and its algorithm
Ayesha Tahir
 
What Is User Datagram Protocol?
What Is User Datagram Protocol?What Is User Datagram Protocol?
What Is User Datagram Protocol?
Simplilearn
 
Tcp and udp.transmission control protocol.user datagram protocol
Tcp and udp.transmission control protocol.user datagram protocolTcp and udp.transmission control protocol.user datagram protocol
Tcp and udp.transmission control protocol.user datagram protocol
Mushtaque Khan Noonari
 
SECURING DATA TRANSFER IN THE CLOUD THROUGH INTRODUCING IDENTIFICATION PACKET...
SECURING DATA TRANSFER IN THE CLOUD THROUGH INTRODUCING IDENTIFICATION PACKET...SECURING DATA TRANSFER IN THE CLOUD THROUGH INTRODUCING IDENTIFICATION PACKET...
SECURING DATA TRANSFER IN THE CLOUD THROUGH INTRODUCING IDENTIFICATION PACKET...
IJNSA Journal
 

Similar to User Datagram protocol For Msc CS (20)

UDP and TCP header.ppt
UDP and TCP header.pptUDP and TCP header.ppt
UDP and TCP header.ppt
 
07 coms 525 tcpip - udp
07    coms 525 tcpip - udp07    coms 525 tcpip - udp
07 coms 525 tcpip - udp
 
Chap 14
Chap 14Chap 14
Chap 14
 
EE281FINALREPORT
EE281FINALREPORTEE281FINALREPORT
EE281FINALREPORT
 
Computer Communication Networks- TRANSPORT LAYER PROTOCOLS
Computer Communication Networks- TRANSPORT LAYER PROTOCOLSComputer Communication Networks- TRANSPORT LAYER PROTOCOLS
Computer Communication Networks- TRANSPORT LAYER PROTOCOLS
 
unit 3 ns.ppt
unit 3 ns.pptunit 3 ns.ppt
unit 3 ns.ppt
 
Tcp and udp
Tcp and udpTcp and udp
Tcp and udp
 
CN Activity 3.pptx
CN Activity 3.pptxCN Activity 3.pptx
CN Activity 3.pptx
 
Transport Layer Numericals
Transport Layer NumericalsTransport Layer Numericals
Transport Layer Numericals
 
Chapter Five - Transport Layer.pptx
Chapter Five - Transport Layer.pptxChapter Five - Transport Layer.pptx
Chapter Five - Transport Layer.pptx
 
UNit-4 Transport Layer and its protocols.pdf
UNit-4 Transport Layer  and its protocols.pdfUNit-4 Transport Layer  and its protocols.pdf
UNit-4 Transport Layer and its protocols.pdf
 
TCP Vs UDP
TCP Vs UDP TCP Vs UDP
TCP Vs UDP
 
TCP AND UDP
TCP AND UDP TCP AND UDP
TCP AND UDP
 
Introduction of tcp, ip & udp
Introduction of tcp, ip & udpIntroduction of tcp, ip & udp
Introduction of tcp, ip & udp
 
UDP and TCP Protocol & Encrytion and its algorithm
UDP and TCP Protocol & Encrytion and its algorithmUDP and TCP Protocol & Encrytion and its algorithm
UDP and TCP Protocol & Encrytion and its algorithm
 
What Is User Datagram Protocol?
What Is User Datagram Protocol?What Is User Datagram Protocol?
What Is User Datagram Protocol?
 
Tcp and udp.transmission control protocol.user datagram protocol
Tcp and udp.transmission control protocol.user datagram protocolTcp and udp.transmission control protocol.user datagram protocol
Tcp and udp.transmission control protocol.user datagram protocol
 
Transport layer
Transport layerTransport layer
Transport layer
 
Chap 11
Chap 11Chap 11
Chap 11
 
SECURING DATA TRANSFER IN THE CLOUD THROUGH INTRODUCING IDENTIFICATION PACKET...
SECURING DATA TRANSFER IN THE CLOUD THROUGH INTRODUCING IDENTIFICATION PACKET...SECURING DATA TRANSFER IN THE CLOUD THROUGH INTRODUCING IDENTIFICATION PACKET...
SECURING DATA TRANSFER IN THE CLOUD THROUGH INTRODUCING IDENTIFICATION PACKET...
 

Recently uploaded

Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdfAdversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Po-Chuan Chen
 
The Roman Empire A Historical Colossus.pdf
The Roman Empire A Historical Colossus.pdfThe Roman Empire A Historical Colossus.pdf
The Roman Empire A Historical Colossus.pdf
kaushalkr1407
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
siemaillard
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
camakaiclarkmusic
 
The Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptxThe Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptx
DhatriParmar
 
Embracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic ImperativeEmbracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic Imperative
Peter Windle
 
Thesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.pptThesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.ppt
EverAndrsGuerraGuerr
 
Guidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th SemesterGuidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th Semester
Atul Kumar Singh
 
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCECLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
BhavyaRajput3
 
Model Attribute Check Company Auto Property
Model Attribute  Check Company Auto PropertyModel Attribute  Check Company Auto Property
Model Attribute Check Company Auto Property
Celine George
 
1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx
JosvitaDsouza2
 
Unit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdfUnit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdf
Thiyagu K
 
Home assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdfHome assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdf
Tamralipta Mahavidyalaya
 
Introduction to AI for Nonprofits with Tapp Network
Introduction to AI for Nonprofits with Tapp NetworkIntroduction to AI for Nonprofits with Tapp Network
Introduction to AI for Nonprofits with Tapp Network
TechSoup
 
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXXPhrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
MIRIAMSALINAS13
 
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
EugeneSaldivar
 
Honest Reviews of Tim Han LMA Course Program.pptx
Honest Reviews of Tim Han LMA Course Program.pptxHonest Reviews of Tim Han LMA Course Program.pptx
Honest Reviews of Tim Han LMA Course Program.pptx
timhan337
 
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
MysoreMuleSoftMeetup
 
678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf
CarlosHernanMontoyab2
 
2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...
Sandy Millin
 

Recently uploaded (20)

Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdfAdversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
 
The Roman Empire A Historical Colossus.pdf
The Roman Empire A Historical Colossus.pdfThe Roman Empire A Historical Colossus.pdf
The Roman Empire A Historical Colossus.pdf
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
 
The Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptxThe Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptx
 
Embracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic ImperativeEmbracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic Imperative
 
Thesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.pptThesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.ppt
 
Guidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th SemesterGuidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th Semester
 
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCECLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
CLASS 11 CBSE B.St Project AIDS TO TRADE - INSURANCE
 
Model Attribute Check Company Auto Property
Model Attribute  Check Company Auto PropertyModel Attribute  Check Company Auto Property
Model Attribute Check Company Auto Property
 
1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx
 
Unit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdfUnit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdf
 
Home assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdfHome assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdf
 
Introduction to AI for Nonprofits with Tapp Network
Introduction to AI for Nonprofits with Tapp NetworkIntroduction to AI for Nonprofits with Tapp Network
Introduction to AI for Nonprofits with Tapp Network
 
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXXPhrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
Phrasal Verbs.XXXXXXXXXXXXXXXXXXXXXXXXXX
 
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
 
Honest Reviews of Tim Han LMA Course Program.pptx
Honest Reviews of Tim Han LMA Course Program.pptxHonest Reviews of Tim Han LMA Course Program.pptx
Honest Reviews of Tim Han LMA Course Program.pptx
 
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
Mule 4.6 & Java 17 Upgrade | MuleSoft Mysore Meetup #46
 
678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf
 
2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...
 

User Datagram protocol For Msc CS

  • 1. 11 User Datagram Protocol (UDP)
  • 2. UDP is a communications protocol that offers a limited amount of service when messages are exchanged between computers in a network that uses the Internet Protocol (IP). UDP is an alternative to the Transmission Control Protocol (TCP) and, together with IP, is sometimes referred to as UDP/IP. Like the Transmission Control Protocol, UDP uses the Internet Protocol to actually get a data unit (called a datagram) from one computer to another. 22 Unlike TCP, however, UDP does not provide the service of dividing a message into packets (datagrams) and reassembling it at the other end. Specifically, UDP doesn't provide sequencing of the packets that the data arrives in. This means that the application program that uses UDP must be able to make sure that the entire message has arrived and is in the right order. Network applications that want to save processing time because they have very small data units to exchange (and therefore very little message reassembling to do) may prefer UDP to TCP. The Trivial File Transfer Protocol (TFTP) uses UDP instead of TCP.
  • 3. The User Datagram Protocol (UDP) is one of the core members of the Internet protocol suite (the set of network protocols used for the Internet). With UDP, computer applications can send messages, in this case referred to as datagrams , to other hosts on an Internet Protocol (IP) network without prior communications to set up special transmission channels or data paths. The protocol was designed by David P. Reed in 1980 and formally defined in RFC 768. 33
  • 4. 4
  • 5. 5
  • 6. UDP is located between the application layer and the IP layer, and serves as the intermediary between the application programs and the network operations. 66
  • 7. 77 Figure 14.1 Position of UDP in the TCP/IP protocol suite
  • 8. Applications Numerous key Internet applications use UDP, including: the Domain Name System (DNS), where queries must be fast and only consist of a single request followed by a single reply packet, the Simple Network Management Protocol (SNMP), the Routing Information Protocol (RIP)[2] and the Dynamic Host Configuration Protocol (DHCP). Voice and video traffic is generally transmitted using UDP many businesses are finding that a recent increase in UDP traffic from these real-time applications is hindering the performance of applications using TCP, such as point of sale, accounting, and database systems. When TCP detects packet loss, 88
  • 9. 99 USER DATAGRAM UDP packets, called user datagrams, have a fixed-size header of 8 bytes.
  • 10. Example The following is a dump of a UDP header in hexadecimal format. 1100 a. What is the source port number? b. What is the destination port number? c. What is the total length of the user datagram? d. What is the length of the data? f. What is the client process?
  • 11. Solution a. The source port number is the first four hexadecimal digits (CB84)16 or 52100. b. The destination port number is the second four hexadecimal digits (000D)16 or 13. c. The third four hexadecimal digits (001C)16 define the length of the whole UDP packet as 28 bytes. d. The length of the data is the length of the whole packet minus the length of the header, or 28 – 8 = 20 bytes. f. The client process is the Daytime (see Table 14.1). 1111
  • 12. 1122
  • 13. 1133 Encapsulation and decapsulation
  • 15. Multiplexing and demultiplexing TCP/IIPP PPrroottooccooll SSuuiittee 1155
  • 16. 1166 UDP is an example of the Note connectionless simple protocol with the exception of an optional checksum added to packets for error detection.
  • 17. A client-server application such as DNS uses the services of UDP because a client needs to send a short request to a server and to receive a quick response from it. The request and response can each fit in one user datagram. Since only one message is exchanged in each direction, the connectionless feature is not an issue; the client or server does not worry that messages are delivered out of order. 1177 Why UDP?
  • 18. A client-server application such as SMTP which is used in electronic mail, cannot use the services of UDP because a user can send a long e-mail message, which may include multimedia (images, audio, or video). If the application uses UDP and the message does not fit in one single user datagram, the message must be split by the application into different user datagrams. Here the connectionless service may create problems. The user datagrams may arrive and be delivered to the receiver application out of order. The receiver application may not be able to reorder the pieces. This means the connectionless service has a disadvantage for an application program that sends long messages. 1188
  • 19. Assume we are downloading a very large text file from the Internet. We definitely need to use a transport layer that provides reliable service. We don’t want part of the file to be missing or corrupted when we open the file. The delay created between the delivery of the parts are not an overriding concern for us; we wait until the whole file is composed before looking at it. In this case, UDP is not a suitable transport layer. 1199
  • 20. 2200 UDP PACKAGE To show how UDP handles the sending and receiving of UDP packets, we present a simple version of the UDP package. We can say that the UDP package involves five components: a control-block table, input queues, a control-block module, an input module, and an output module.
  • 21. UDP design TCP/IIPP PPrroottooccooll SSuuiittee 2211
  • 22. 2222
  • 23. 2233
  • 24. 2244
  • 25. 2255
  • 26. The first activity is the arrival of a user datagram with destination port number 52,012. The input module searches for this port number and finds it. Queue number 38 has been assigned to this port, which means that the port has been previously used. The input module sends the data to queue 38. The control-block table does not change. After a few seconds, a process starts. It asks the operating system for a port number and is granted port number 52,014. Now the process sends its ID (4,978) and the port number to the control-block module to create an entry in the table. The module takes the first FREE entry and inserts the information received. The module does not allocate a queue at this moment because no user datagrams have arrived for this destination (see Table 14.6). A user datagram now arrives for port 52,011. The input module checks the table and finds that no queue has been allocated for this destination since this is the first time a user datagram has arrived for this destination. The module creates a queue and gives it a number (43). See Table 14.7. After a few seconds, a user datagram arrives for port 52,222. The input module checks the table and cannot find an entry for this destination. The user datagram is dropped and a request is made to ICMP to send an unreachable port message to the source. 2266
  • 27. 2277
  • 28. 2288 Reliability and congestion control solutions Lacking reliability, UDP applications must generally be willing to accept some loss, errors or duplication. Some applications, such as TFTP, may add rudimentary reliability mechanisms into the application layer as needed. Most often, UDP applications do not employ reliability mechanisms and may even be hindered by them. Streaming media, real-time multiplayer games and voice over IP (VoIP) are examples of applications that often use UDP. In these particular applications, loss of packets is not usually a fatal problem. If an application requires a high degree of reliability, a protocol such as the Transmission Control Protocol may be used instead.
  • 29. 2299