1. Overview

In this tutorial, we’ll discuss packet loss in computer networking.

We’ll explore the main reasons for the packet loss in the User Datagram Protocol (UDP).

2. Introduction to UDP

Information in networking transmitted through wide area networks (WANs) utilizes UDP to implement several networking applications such as video and audio streaming. UDP is a connectionless protocol. Additionally, UDP decreases network latency. Furthermore, it excludes handshake and doesn’t require a connection setup between source and destination.

However, the transmission of information using UDP can’t provide flow control through a communication process. Hence, using UDP, we can’t detect lost packets. Therefore, retransmission of the lost packets is not possible.

Real-time applications mainly use UDP. However, a packet being lost without detection makes UDP an unreliable protocol. Packet loss is one of the major challenges in networking when using UDP. Additionally, as there’s no error control mechanism in UDP, it simply discards the packet as soon as an error is detected. Furthermore, transmitting a lot of data using UDP may cause congestion in a network.

On the other hand, UDP minimizes transmission delay. Additionally, it doesn’t require establishing a connection between the sender and the receiver. Furthermore, it offers broadcast and multicast transmission. UDP utilizes a small header. Hence, it takes less time to process the packets.

3. Packet Loss in Networking

Now in order to investigate the core reasons for packet loss in any network communication, let’s start the discussion with the different layers in networking. Based on the OSI model, any networking device can communicate with each other via seven layers: Application Layer, Presentation Layer, Session Layer, Transport Layer, Network Layer, Datalink Layer, and Physical Layer. Each layer is responsible for carrying out specific functions:

sdascas.drawio

Out of 7 layers, data transmission is a part of the networking layer. Although, the transport layer is responsible for the complete delivery of the packets. In general, packet loss refers to data transmitted through a network but unable to reach its destination. Hence, several factors can cause packet loss, including massive connectivity from a source to a destination, software/hardware issues, and cyber attacks.

The transport layer in the OSI model supports connection-oriented as well as connection-less protocols for the delivery of the packets. It uses Transmission Control Protocol (TCP) for connection-oriented and User Datagram Protocol (UDP) for connection-less delivery service. TCP establishes a connection, breaks the packets into segments, and adds a sequence number with all the segments. Hence, if any segment gets lost while transmission, the receiver requests the sender to retransmit the specific segment.

The UDP doesn’t need to establish a connection before starting transmitting packets. Additionally, it doesn’t support any retransmission method. Furthermore, the structure of UDP packets doesn’t support numbering, making it impossible to determine the number of missing packets from the receiver end. Hence, UDP is unreliable, and the end-to-end delivery of the packets is not guaranteed.

4. Packet Loss in UDP

Let’s say the sender sends n number of packets to a receiver. The receiver received m number of packets. If  m < n, there’s packet loss in the network. The UDP protocol entirely relies on the network stack, including hardware and software systems. There’re six main reasons for packet loss in UDP: network congestion, hardware Issue, software malfunction, connectivity issue, vulnerabilities, and faulty infrastructure:

packetloss

4.1. Network Congestion

Congestion in the network is the primary reason for packet loss in UDP, as every communication network has a flow limit. For example, network congestion is similar to a traffic jam on the road, where exceeding the maximum number of vehicles allowed on a given road may cause traffic to slow or stop during peak hours.

Congestion in a network can increase the time a packet takes to reach the destination. Hence, it can result in increasing the latency of the network. Additionally, the server waits a specific amount of time in order to receive packets. Due to high latency, we can face connection timeout if the packets don’t arrive in a specified time.

Furthermore, when network traffic reaches its higher connectivity threshold, the transmission of UDP packets is interrupted due to high latency. Since UDP applications are not built to retrieve or resend discarded packets, packet loss occurs.

4.2. Hardware Issue

Upgradation of hardware in networking is vital in order to maintain security and performance. Hardware, like routers, prevents unauthorized packets from entering a network by implementing various functions, including packet routing and traffic management. A firewall is another vital component in a network that filters out incoming and outgoing data.

However, outdated components can considerably weaken network transmission speed and cause packet loss. Unfortunately, some companies ignore the need to modernize hardware, leading to packet loss and connectivity outages. Hence, timely upgrade of the hardware and introduction of modern hardware components is essential in order to reduce packet loss and maintain security.

4.3. Software Malfunction

During network transmission, simultaneous unwanted operations can slow the transfer of packets. Software bugs are related to hardware. Software running on faulty hardware may cause several issues, including packet loss. Hence, it’s crucial to monitor networking hardware at a regular interval. Sometimes fixing or upgrading hardware automatically fixes software bugs.

Additionally, software bugs or glitches in networking can cause transmission failure. UDP transmission might get disrupted due to behavioral malfunctions such as deadlock, reachability failure, lack of liveness actions, and mutual exclusion. The detection of software failure requires software engineers to apply different tests, verification, and validation, which is an expensive task.

Most companies implementing UDP applications don’t include the software’s test procedure, which may increase the likelihood of packet loss during UDP operation processing.

4.4. Connectivity Issue

Network connectivity impacts the packets transmitted through a network. Wired and wireless connectivity can affect the quality of signals positively as well as negatively. Some applications that use wireless connectivity are CCTV cameras, smart video doorbells, and smart sockets with WiFi. Such applications utilize UDP for information transmission. However, wireless signals encounter physical interruptions that impair devices from connected gateways.

Now let’s talk about the obstacles in that environment that can cause packet loss in wireless transfer. Metal, concrete walls, metal lath, ceramic tiles, tinted glass, mirrors, and drywall are examples of the environment that can lead to network packet loss.

The variety of obstacles contributes to blocking signals. Thus, wireless connectivity may result in packet loss because the UDP protocol relies on continuous data streaming. However, packet loss in the wired medium is significantly less compared to the wireless medium.

4.5. Vulnerabilities and Threats

Packet loss in a network might happen due to cyber-attacks and threats. Let’s talk about a popular cyber-attack: Distributed Denial of Service (DDoS) attack. It’s as simple as opening a terminal and executing a ping command to a specific IP address of a device. It can cause the system to shut down for a period of time.

Thus, all the information might get lost if the DDoS attack happens during packet transmission. Hence, as a result, users might not be able to access files, emails, or shared works. Packet loss can be challenging when a system is full of security threats.

The risk from the threats can be reduced by updating the software and hardware of the system at a regular interval.

4.6. Faulty Infrastructure

Engineers sometimes bind equipment to implement some applications where the system’s overall performance may reach its limit without meeting the requirements of the applications. Thereby, these circumstances can conceive bottlenecks that result in prolonged operations, including UDP packet streaming.

Faulty infrastructure can lead to slow performance, configuration errors, sudden hardware failure, server issues, and resource failures.

5. Conclusion

In this tutorial, we discussed several reasons for packet loss in UDP. To minimize packet loss in UDP, one must reduce the faultiness of the network on which UDP packets are transmitted.

We talked about various precautions in order to avoid packet loss. We can prevent packet loss by upgrading software and hardware, analysis of system performance, and hiring specialists to detect vulnerabilities. Additionally, continuous system infrastructure monitoring reduces packet loss in UDP.

Comments are open for 30 days after publishing a post. For any issues past this date, use the Contact form on the site.