- Codel Overview
Codel is a novel “no knobs”, “just works”, “handles variable bandwidth and RTT”, and simple AQM algorithm.
- It is parameterless — no knobs are required for operators, users, or implementers to adjust.
- It treats good queue and bad queue differently - that is, it keeps the delays low while permitting bursts of traffic.
- It controls delay, while insensitive to round-trip delays, link rates, and traffic loads.
- It adapts to dynamically changing link rates with no negative impact on utilization.
CoDel is the fundamental advance in the state of the art of network Active Queue Management in many, many years.
It is pronounced "coddle", because it handles network streams in a gentle way.
With fq_codel it is possible to reduce bottleneck delays by several orders of magnitude, and provide accurate RTT estimates to elephant TCP flows, while allowing shorter (sparser) flows like DNS, ARP, SYN, routing, etc packets priority access.
We don't say several orders of magnitude lightly. We have the benchmarks to back it up.
Papers and Publications¶
Controlling Queue Delay ACM Queue, Kathleen Nichols, Van Jacobson, May, 2012
Codel page at Pollere . Pollere does research on and analysis of network performance via modeling and simulation, measurement,and laboratory prototypes.
Kathie Nichol's CoDel at the IETF-84 Transport Area Open Meeting, 30 July, 2012, Vancouver, Canada, by Van Jacobson.
For a description of how fq_codel works, see the technical description.
Kathie Nichols' and Van Jacobson's original ns2 simulation of codel
Their most current ns2 code is now available via git
Andrew McGregor's ns3 simulation of codel (against v14 of the linux kernel patches). README (obsolete)
Andrew McGregor has moved the codel and fq_codel ns3 simulations into a github repository to bake before submittal to the ns3 mainline.
There are now basically 6 slightly different variants of codel (see Reconciling codel variants), flying in loose formation. The code as published in the original paper is obsolete. Research is continuing. Come help!
Mailing list and chat room¶
There is a CoDel mailing list, and discussions that take place on irc.freenode.net in the #bufferbloat chat room.
CoDel requires the Linux 3.3 Byte Queue Limits . It has proven too hard to backport BQL to Linux 3.2 or earlier (an attempt for 3.2 exists, but no driver support), so you will need to upgrade to Linux 3.5 or later, and have a driver that supports BQL (only about 10 as of the present writing). If you are doing soft rate limiting (eg shaping), BQL is not required at the driver level. Codel and fq_codel are in the Linux 3.5 release - no patches are required, but BQL support is limited, as noted.
While fq_codel and codel are "no knobs" qdiscs, several other knobs can be tweaked for the lowest latency results. An example script for doing that is called "debloat" which is available from the deBloat repository on github. It tunes up BQL, turns off various forms off tcp offloads, and offers both a fq_codel and codel + qfq model to play with.
Initial Linux 3.3 and Linux 3.4 compatible patches, written by Eric Dumazet and Dave Täht, are here but are obsolete.
This codel implementation will work with the bog-standard Linux 'tc' utility in 'no-knobs mode', but to get useful statistics back requires a patch to the iproute2 facility.
Codel specific tc support is now in the "main iproute2 repository on git.kernel.org. Do a
git clone git://git.kernel.org/pub/scm/linux/kernel/git/shemminger/iproute2.git
to get that. Builds of this version of iproute2 are also available as part of debian experimental, and openwrt's main, repo.
Future prototypes of successors to fq_codel will be in the iproute2-debloat repository on github.
The CeroWrt research router project was started, specifically, to test new AQM technologies, and has been tracking codel closely.
A pretty solid build is now available
The fq_codel code has already migrated into the OpenWrt mainline (upon which Cerowrt is based), so the research has paid off! - there is more to come...
Several patches (mostly ECN and ipv6 related) are also backported from 3.5 into the current cerowrt release.
Binary code and kernels for Linux based operating systems:¶
- Kamal Mostafa's Ubuntu PPA for 12.04 (Precise) and 12.10 (Quantal)
- John Linville's Fedora 16 builds
- Any current build of OpenWrt
Code for other operating systems¶
At very low bandwidths (e.g. .5Mbps) on ADSL, we're having to play with the target; Kathie did not have to in her simulations. Likely a bug in the implementation.
People have tried to run CoDel in very big routers, with hundreds of simultaneous flows, a situation not simulated in advance. There, it isn't controlling the queue the way it should: whether this is a problem with the algorithm, or the implementation, is not yet understood.
It is clear that unmodified, CoDel is not appropriate for AQM of traffic inside a data center; it does not react in a timely enough fashion. Whether the modifications of the ideas in CoDel will solve this problem is not yet known. Again, this is an area which CoDel was not designed to solve or it simulated in before publication.