Network scheduler
A network scheduler, also called packet scheduler, is an arbiter program that manages the sequence of network packets in the transmit and receive queues of the network interface controller, which is a circular data buffer. There are several network schedulers available for the different operating system kernels, that implement many of the existing network scheduling algorithms.
Also, network schedulers are enabling accomplishment of the active queue management and traffic shaping.
Implementations
Linux kernel
The currently available network scheduler for the Linux kernel is an integral part of the Linux network stack; it arbiters the ringbuffers of all NICs, hence it works on layer 2 of the OSI model and handles Ethernet frames. It manages the transmit and receive buffers of all present NICs.
The user space programs ifconfig
and ip
enable the system administrator to regulate the buffer sizes: txqueuelen
/rxqueuelen
; the unit being number of Ethernet frames (regardless of their size) for each device separately. The Linux network stack contains several other buffers, which are not managed by the network scheduler. The overall size of all buffers has been the point of critique by the Bufferbloat project.
Another network scheduler is being developed as part of Netfilter.
BSD
ALTQ is the implementation of a network scheduler for Berkeley Software Distribution.
Functioning
The network scheduler logic decides similar to a statistical multiplexer which network packet to forward next from the buffer. The buffer works as a queuing system, where the network packets are stored temporarily until they are transmitted. The buffer space is divided into many queues, each of which is used to hold the packets of one flow, defined for instance by source and destination IP addresses.
The in each case loaded network scheduling algorithm and the settings determine how the network scheduler manages the buffer.
Bufferbloat
High latency and jitter are phenomenons encountered due to the coincidence of bufferbloat and high traffic volume. Though the network scheduler manages only the transmit (and receive) queue of the network controller, and more buffers exist, by the adoption of the CoDel queueing disclipine, a significant reduction of the effect has been achieved.
Network scheduling algorithms
In the course of time several network scheduling algorithms (also called queueing discipline or queueing algorithm) have been developed. There is a rough distinction between leaky bucket and token bucket algorithms, and between class-based and class-less ones. The head drop discipline CoDel is less prone to the effects of bufferbloat then the common tail drop disciplines.
Several scheduling algorithms suited for the task of managing network packets have been implemented as Linux kernel modules[1] and are freely available:
- AVQ (Adaptive Virtual Queue)[2]
- CBQ (Class-based queueing) discipline
- CHOKe (CHOose and Keep for responsive flows, CHOose and Kill for unresponsive flows) is a variant of RED
- CoDel (Controlled Delay) and Fair Queue CoDel
- Credit-based fair queuing
- DRR (Deficit round robin) and DWRR, implementation e.g. written by Patrick McHardy for the Linux kernel[3] and published under the GNU General Public License.
- HFSC (Hierarchical Fair Service Curve)
- NETEM Network emulator[4]
- HTB (Hierarchy Token Bucket)[5]
- QFQ (Quick Fair Queueing)[6]
- FQ (Fair queuing) and WFQ (Weighted fair queuing)
- pkt_sched: fq: Fair Queue packet scheduler [7]
- RED (Random early detection) as well as ARED, GRED, RRED (Robust random early detection) und WRED (Weighted random early detection)
- SFB (Stochastic Fair Blue) as well as Resilient SFB
- SFQ (Stochastic Fairness Queueing)[8]
- TBF (Token Bucket Filter)[9]
- TEQL (Trivial Link Equalizer)
- RR (Round-robin) and WRR (Weighted round robin)
Buzzwords
Though the task of a network scheduler is not that complicated, a lot of buzzwords are around:
- Active Queue Management (AQM) – the employment of an arbiter program
- Network Traffic Control – an umbrella term for all measures aimed at the control of traffic
- Traffic shaping – a form of AQM, where the available bandwidth is being limited to match certain use cases
- Link Sharing – usually used when more individuals share the same Internet connection
- Traffic Prioritizing – a form of AQM, that selective prioritizes certain network packets (e.g. VoIP-packets)
- TCP Turbo – winner of the buzzword contest, accentuates, that by prioritizing ACK packages on the upload, the download rate of a TCP connection is not slowed down
- Bandwidth Management – the management of the available bandwidth
See also
|
References
- ↑ "The Linux kernel network scheduler". kernel.org. 2012-12-26. Retrieved 2013-09-07.
- ↑ http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.108.4477&rep=rep1&type=pdf
- ↑ "DRR Linux kernel network scheduler module". kernel.org. Retrieved 2013-09-07.
- ↑ "Network emulator Linux kernel network scheduler module". kernel.org. Retrieved 2013-09-07.
- ↑ "HTB Linux kernel network scheduler module". kernel.org. Retrieved 2013-09-07.
- ↑ "QFQ Linux kernel network scheduler module". kernel.org. Retrieved 2013-09-07.
- ↑ "Fair Queue packet scheduler committed to Linux kernel 3.12".
- ↑ "SFQ Linux kernel network scheduler module". kernel.org. Retrieved 2013-09-07.
- ↑ "TBF Linux kernel network scheduler module". kernel.org. Retrieved 2013-09-07.