In the grand scheme of things, it probably isn't a big deal, but I get annoyed when something isn't running top notch.

I noticed on a clean docker build, when running containers I was getting an error:

WARNING: Your kernel does not support memory swappiness capabilities, memory swappiness discarded.

A bit ominous no? How could this be, I know my machine has SWAP, and there's a SWAP partition mounted. I tossed the error into Google and came back with a few unhelpful forum postings.

Later, I discovered that docker info was outputting similar errors.

WARNING: No swap limit support  
WARNING: No memory limit support  

Just as ominous and unhelpful as the first error. It was back Google where I discovered this little gem that posted the fix.

A simple modification to the GRUB_CMDLINE_LINUX_DEFAULT line in/etc/default/grub with the following:

GRUB_CMDLINE_LINUX_DEFAULT="quiet cgroup_enable=memory swapaccount=1"  

Then running sudo update-grub to seal the deal.

Now we have resolution, no more ominous errors when running containers, but what was the root cause?

It turns out that Debian (and some Ubuntu/Mint) distros do not ship with Control Groups enabled. Control groups give Linux containers the ability track and expose relevant metrics for memory and other core kernel components. Essentially, control groups allow for the policing of your memory, CPU, and I/O usage. Neat.

You can read more here: https://www.kernel.org/doc/Documentation/cgroups/cgroups.txt++

That's all for now.

Beware the JabberWock, my son!

~awh