Network delays are usually small. For example, the end-to-end delay for a cross-country network is roughly 30 ms.
However, packets can get lost in a network. Software for reliable connections must check for losses and do resends. If a resend is needed, the overall delay is at least doubled: the another round-trip time is added for a resend request and response. For higher speed reliable data transfer protocols the impact can be even greater.
This web page examines first the delay equation which breaks down network delays into easier to analyse components. It then examines some of the causes of packet losses.
d_{nodal} | = |
d_{proc} | + |
d_{queue} | + |
d_{trans} | + |
d_{prop} |
The delay equation below describes the packet delay at a single node along its route from source to destination.
The nodal processing delay d_{proc} is the time that a node spends processing a packet. This includes time for error checking, time for reading the packet header, and time for looking up the link to the next node, based on the destination address. Although the processing may sound complicated, the nodal processing delay is usually negligible compared to other terms in the delay equation.
The queuing delay d_{queue} is the time that a packet spends in a queue at a node while waiting for other packets to be transmitted. If the node is a high-speed router then there is one queue for each outgoing link, so a packet waits only for other packets that are going across the same link.
The queuing delay is related to the transmission delay d_{trans} by the following approximate equation.
d_{queue} | = |
d_{trans} | *_{} | l_{queue} |
Here, l_{queue} is the average length of the queue. The average queue length depends on the load factor, which is the ratio of the attempted link transmission rate to the link maximum transmission rate. The average queue length is typically less than 1 for a load factor less than 1/2. When the load factor exceeds 1, the queue length grows without bound.
The transmission delay d_{trans} is the time required to put an entire packet into the communication media. It can be computed by the following equation.
d_{trans} | = |
L/R_{} |
Here, L is the length of a packet in bits and R is the transmission rate in bits per time unit. The time unit in d_{trans} and R should be the same.
The propagation delay d_{prop} is the time that it takes a signal change to propagate through the communication media from a node to the next node. It can be computed using the following equation.
d_{prop} | = |
D/s_{} |
Here, D is the distance from the node to the next node and s is propagation speed of the media.
For links using radio broadcast, a signal change propagates at close to the speed of light, which is about 186,000 miles per second. For copper and fiber links, a signal change propagates at 60% to 80% of the speed of light. For back-of-the-envelope calculations in copper or fiber links, 100,000 miles per second is a convenient approximation to the propagation speed.
Queue overflow occurs when an output link from a node has a load factor that exceeds 1.0. That is, data is arriving at the queue for the link faster than it can be transmitted. As a result, queue length grows until there is no more space in the queue. At that time, a node has no choice but to discard a packet.
A small amount of noise is present in any electronic circuit. Even more noise may be generated by nearby appliances or lightning activity. This noise can cause bits to be changed from 0 to 1 or vice versa. Normally, this causes error checks to fail. Most nodes will then just discard the packet that contains the error.
Different media have different susceptibility to noise. Fiber media generally have the lowest noise levels. Coaxial cable has low noise, but not as low as fiber. Twisted pair cabling is somewhat more susceptible to noise than coaxial cable. Unguided media (radio and satellite broadcast) are the most susceptible to noise for two reasons:
The following delay calculations assume a packet length of 1Kbits and a media propagation speed of 100,000 miles per second. Then the reciprocal of the propagation speed is 10 microseconds per mile. Dividing by the speed is the same as multiplying by the reciprocal of the speed.
The following values are typical for a LAN:
Then we have
The queue delay d_{queue} depends on the load factor. If the load factor is less than 0.1 then the queue delay is almost always smaller than the transmission delay. If the load factor is less than 0.5 then the queue delay is no more than 2 or 3 times the transmission delay.
For modern network equipment, the nodal processing delay is insignificant. The above calculations show that the transmission delay is the most significant component of the nodal delay for a lightly loaded link, but the queue delay dominates for a heavily loaded link.
The following values are typical for a WAN:
Then we have
The queue delay d_{queue} depends on the load factor, but is small compared to the propagation delay unless the load factor is close to 1.0.
For modern network equipment, the nodal processing delay is insignificant. The above calculations show that the propagation delay is the most significant component of the nodal delay.
The delay equation breaks down network delays into easier to analyse components. Network delays are usually small, as indicated by example calculations. However, packets can get lost in a network, which increases the impact of delays.
The packet delay is broken up into a sequence of nodal delays.
Each nodal delay, d_{nodal}, can be calculated with the following equation.
d_{nodal} | = |
d_{proc} | + |
d_{queue} | + |
d_{trans} | + |
d_{prop} |
The nodal processing delay, d_{proc}, is the time that a node spends processing a packet. It is usually negligible compared to other terms.
The queuing delay, d_{queue}, is the time that a packet spends in a queue at a node while waiting for other packets to be transmitted. It is related to the transmission delay d_{trans} by the following approximate equation.
d_{queue} | = |
d_{trans} | *_{} | l_{queue} |
The transmission delay d_{trans} is the time required to put an entire packet into the communication media. It can be computed by the following equation.
d_{trans} | = |
L/R_{} |
The propagation delay d_{prop} is the time that it takes a signal change to propagate through the communication media from a node to the next node. It can be computed using the following equation.
d_{prop} | = |
D/s_{} |
In a LAN, the transmission delay dominates for a lightly loaded link, but the queuing delay dominates for a heavily loaded link.
In a WAN, the propagation delay is the dominant component.
Packets are lost for two reasons:
Queue overflow only occurs for heavily loaded links. Packet loss due to noise is primarily dependent on the link media. It is more significant for unguided media.