User Datagram Protocol (UDP) (article) | Khan Academy (2024)

Want to join the conversation?

Log in

  • Yizuhi Galaviz

    4 years agoPosted 4 years ago. Direct link to Yizuhi Galaviz's post “UDP doesn't do anything a...”

    UDP doesn't do anything about packets arriving out of order, right? Is that why sometimes, in live streaming, the audio and video are not synchronized? Or why the live streams sometimes lag?

    (58 votes)

    • Martin

      4 years agoPosted 4 years ago. Direct link to Martin's post “Yes, UDP does without han...”

      User Datagram Protocol (UDP) (article) | Khan Academy (4)

      User Datagram Protocol (UDP) (article) | Khan Academy (5)

      User Datagram Protocol (UDP) (article) | Khan Academy (6)

      Yes, UDP does without handshakes. That means the information received is somewhat unreliable when it comes to ordering, duplicates and packets arriving at all.
      And you correctly identified the problems that arise with that :)

      (53 votes)

  • layaz7717

    4 years agoPosted 4 years ago. Direct link to layaz7717's post “What might cause data to ...”

    What might cause data to become corrupted? Also, when you get the notification that a file is corrupted, does it have the same meaning? The data has gotten messed up somehow?

    (9 votes)

    • Shane McGookey

      4 years agoPosted 4 years ago. Direct link to Shane McGookey's post “It might be helpful to co...”

      User Datagram Protocol (UDP) (article) | Khan Academy (10)

      User Datagram Protocol (UDP) (article) | Khan Academy (11)

      It might be helpful to consider what "data" is. In this context, we are talking about data that is transmitted over a network. If you are using a personal computer, then the process of transmitting data over a network involves transitioning data from your HDD or SSD to your computer's RAM via internal buses, and then to the NIC (Network Interface Card) to communicate it across a network. The data (which is represented using binary) must then traverse the connection between your device and the device you are sending data to. This traversal could entail moving the data over a WiFi network, over Ethernet cables, etc.

      This is an extensive process, and we certainly take for granted its complexity when we interact with the Internet each and every day. If during this process any bits of the data (again, data is being represented as binary; 1s and 0s) were to flip (go from 0 to 1, or 1 to 0) or were to be lost then the data received by the receiving machine wouldn't be the same as what was originally sent. In this case, the machine may not be able to interpret the data anymore - as it has lost its meaning - and so you end up with data corruption.

      To your latter question, yes. When information saved to the machine's non-volatile storage has been saved incorrectly and has thus lost its meaning, then the computer will notify you that the data has been corrupted.

  • layaz7717

    4 years agoPosted 4 years ago. Direct link to layaz7717's post “What exactly happens when...”

    What exactly happens when videos start to glitch? For example, in Zoom meetings, sometimes people tend to look all "blocky" and the details in their video are not defined. Is that something to do with data corruption?

    (10 votes)

    • Martin

      4 years agoPosted 4 years ago. Direct link to Martin's post “Yes, that generally indic...”

      User Datagram Protocol (UDP) (article) | Khan Academy (15)

      Yes, that generally indicates issues with packages, a lot of packets actually (a single dropped packets could be easily dealt with because of error-correcting encodings), generally it will just be a little blurriness or wobbly sound or something similarly barely noticeable.

      (12 votes)

  • Dhairya Patel

    2 years agoPosted 2 years ago. Direct link to Dhairya Patel's post “Is it possible for the da...”

    Is it possible for the data in the checksum (the two bytes) to be corrupt?

    (5 votes)

    • KLaudano

      2 years agoPosted 2 years ago. Direct link to KLaudano's post “Yes, any part of the pack...”

      Yes, any part of the packet could end up being corrupted during transmission.

      (6 votes)

  • green_ninja

    4 years agoPosted 4 years ago. Direct link to green_ninja's post “Hi!I'm having trouble w...”

    Hi!

    I'm having trouble with adding binary numbers. I watched a few of Khan Academy's videos on YouTube, but I don't understand the mathematical reasoning behind it. Can someone please explain?

    Thanks!

    (5 votes)

    • washiwalajulius

      2 months agoPosted 2 months ago. Direct link to washiwalajulius's post “In decimal the maximum su...”

      In decimal the maximum sum is 9 before you move or add another number next to it e.g
      4
      +5
      = 9
      but
      1
      +9
      =10(we go back to zero ten since we passed the maximum sum (9) and carry 1 to the left n it becomes 10)
      in binary (base 2) its the same thing just that the maximum ti move to the next line here is 1.
      1
      +0
      =1
      1
      +1
      =10 (remember maximum sum that u can represent as a single number is 1 in binary just like 9 in base 10 or decimal)
      After reaching our maximum we carry the reminder to the next number on the left side.
      another binary example
      10
      + 11
      =101
      Hope you can get it from here
      1 last example to cement
      111
      + 111
      01110
      notice 1+1+1 = 1 carry 1 to the left
      1+1 = 0 carry/move 1 to the left/next number

      (2 votes)

  • joseandresdurand

    a year agoPosted a year ago. Direct link to joseandresdurand's post “If UDP performs the check...”

    If UDP performs the checksum when the recipient receives the data, is this calculation done for every segment it receives? Is it done in the routers? And finally, does this verification not affect the data transmission speed?

    (1 vote)

    • anonymous

      a year agoPosted a year ago. Direct link to anonymous's post “UDP (User Datagram Protoc...”

      User Datagram Protocol (UDP) (article) | Khan Academy (25)

      UDP (User Datagram Protocol) is a connectionless protocol used for transmitting data over a network. Unlike TCP, UDP does not include mechanisms for flow control, error recovery, or ensuring data delivery in order. Let's address your questions regarding UDP checksum, its verification, and its impact on data transmission speed:

      Checksum Calculation:
      When data is sent using UDP, a checksum is calculated over the data and included in the UDP header. This checksum is used to detect errors in the data during transmission. The checksum is calculated based on the data in each segment, along with some header information. It's important to note that this checksum is calculated by the sender before the data is transmitted, not by the recipient.

      Checksum Verification:
      Upon receiving a UDP segment, the recipient uses the checksum value in the UDP header to verify the integrity of the received data. If the calculated checksum at the receiver's end does not match the checksum in the header, it indicates that the data might have been corrupted during transmission. In such cases, the receiver may choose to discard the corrupted segment or take other appropriate actions based on the application's requirements.

      Checksum Calculation Frequency:
      The checksum is calculated for each individual UDP segment sent by the sender. Each segment is treated separately, and the checksum calculation is not done at the routers. Routers typically operate at the network layer (IP layer) and don't usually involve themselves with the details of transport-layer protocols like UDP.

      Impact on Data Transmission Speed:
      Calculating and verifying the checksum does add some overhead to the data transmission process, as it involves performing mathematical operations on the data. However, the impact on data transmission speed is relatively low compared to the benefits of error detection. UDP is often used in scenarios where speed and low latency are prioritized over the guaranteed delivery and error recovery mechanisms of TCP.

      That being said, the impact of checksum calculation and verification on data transmission speed can vary depending on factors such as the processing power of the sender and receiver, the network's speed, and the frequency at which data is being transmitted.

      In summary, UDP performs checksum calculation on the sender's side for each segment, and the checksum is verified on the recipient's side. While the checksum calculation does introduce some overhead, the impact on data transmission speed is generally manageable, especially in applications where real-time communication and low latency are important.

      (12 votes)

  • Aland Soran

    2 years agoPosted 2 years ago. Direct link to Aland Soran's post “Are the terms package, pa...”

    Are the terms package, packet and segment referring to the same thing? if not, could you please define each one? thank you

    (2 votes)

    • KLaudano

      2 years agoPosted 2 years ago. Direct link to KLaudano's post “"Package" is an informal ...”

      User Datagram Protocol (UDP) (article) | Khan Academy (29)

      "Package" is an informal term that people seem to use in place of "packet".

      Segments, packets, and frames are created at different layers in the OSI model and each adds its own header to the data with more information. Segments are created at the transport layer and include port numbers. Packets are created at the network layer from segments and have IP addresses. Frames are created at the data link layer from segments and have MAC addresses.

      (I know you didn't ask about frames, but for the sake of completeness I felt it should be added.)

      (10 votes)

  • Neev Badu

    4 years agoPosted 4 years ago. Direct link to Neev Badu's post “https://cdn.kastatic.org/...”

    (2 votes)

    • pamela ❤

      4 years agoPosted 4 years ago. Direct link to pamela ❤'s post “Good question! The 4 byte...”

      Good question! The 4 bytes is the width of the header. Together, the source port number and destination port number in the first row take up 4 bytes. Since they're shown equal sized, each of them take up 2 bytes (16 bits). Similarly the segment length and checksum together take up 4 bytes, and each take up 2 bytes.

      (9 votes)

  • Morteza Saharkhiz

    4 years agoPosted 4 years ago. Direct link to Morteza Saharkhiz's post “Section Segment Length sa...”

    Section Segment Length says that "Two bytes is 2^{16} bits" which is typo, right? 2 bytes is 16 bits and can store 2^{16} possible values.

    (3 votes)

  • MaryTheBest

    a year agoPosted a year ago. Direct link to MaryTheBest's post “Can the _checksum_ be cor...”

    Can the checksum be corrupted, and if so, is there a way for the UDP to deal with that?

    (1 vote)

    • KLaudano

      a year agoPosted a year ago. Direct link to KLaudano's post “Yes, any part of the pack...”

      Yes, any part of the packet could be corrupted, including the checksum. If the checksum were corrupted, the computer has no way of knowing whether the checksum was corrupted or the data was. All the computer would know is that the given checksum does not match the data's checksum, so the packet would likely be discarded.

      (6 votes)

User Datagram Protocol (UDP) (article) | Khan Academy (2024)

References

Top Articles
NBA 2K23: Best MyPlayer Builds
NBA 2K23 Best All Around Builds For C, PF, SF, PG, SG Position (Current & Next Gen)
Swissport Timecard
Words With Friends Cheat Board Layout 11X11
Yale College Confidential 2027
Is Whitney Williams Wgem Married
Royal Bazaar Farmers Market Tuckernuck Drive Richmond Va
Best Taq 56 Loadout Mw2 Ranked
Nazir Afzal on the BBC: ‘Powerful predators were allowed to behave terribly on an industrial level’
Mileage To Walmart
What is international trade and explain its types?
Craigslist/Phx
Poochies Liquor Store
Top Scorers Transfermarkt
Lesson 10 Homework 5.3
Apple Store Location
Bailu Game8
2023 GMC Yukon Price, Cost-to-Own, Reviews & More | Kelley Blue Book
Mobile Maher Terminal
Violent Night Showtimes Near The Riviera Cinema
North Colonie Continuing Education
Creigs List Maine
Ghostbusters Afterlife 123Movies
Restaurants Near Defy Trampoline Park
Disney Cruise Line
Springfield Ma Craigslist
Snow Rider Unblocked 67
Bluestacks How To Change Master Instance
25+ Irresistible PowerXL Air Fryer Recipes for Every Occasion! – ChefsBliss
Cluster Truck Unblocked Wtf
Prisoners Metacritic
Erfolgsfaktor Partnernetzwerk: 5 Gründe, die überzeugen | SoftwareOne Blog
Eastman Classifieds Kingsport
Hmnu Stocktwits
Stellaris Resolution
Black Adam Showtimes Near Cinergy Amarillo
Snowy Hydro Truck Jobs in All Sydney NSW - Sep 2024 | SEEK
Horseheads Schooltool
Mudae Disable Tags
Colonial Interceptor
Sayuri Pilkey
Game On Classroom 6X
Jcp Meevo Com
Connie Mason - Book Series In Order
Download Diablo 2 From Blizzard
Souvenir Shopping and Local Markets in Belgium
Ucla Outlook Web Access
How To Get Genji Cute Spray
8 Internet Celebrities who fell prey to Leaked Video Scandals
Cargurus Button Girl
Latest Posts
Article information

Author: Annamae Dooley

Last Updated:

Views: 6472

Rating: 4.4 / 5 (45 voted)

Reviews: 84% of readers found this page helpful

Author information

Name: Annamae Dooley

Birthday: 2001-07-26

Address: 9687 Tambra Meadow, Bradleyhaven, TN 53219

Phone: +9316045904039

Job: Future Coordinator

Hobby: Archery, Couponing, Poi, Kite flying, Knitting, Rappelling, Baseball

Introduction: My name is Annamae Dooley, I am a witty, quaint, lovely, clever, rich, sparkling, powerful person who loves writing and wants to share my knowledge and understanding with you.