Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm investigating some application issues on a Linux system and noticed this around the time of the most recent problem, but not close enough to be definitively related:

Jun  7 17:51:49 localhost kernel: shrink_slab: nr=-155456000
Jun  7 17:51:49 localhost kernel: shrink_slab: nr=-157859400
Jun  7 17:51:49 localhost kernel: shrink_slab: nr=-157833400
Jun  8 06:20:23 localhost kernel: shrink_slab: nr=-284172800

What is this? Googling isn't helping, I get that it's something with VM, but why is it suddenly showing up in /var/log/messages?

Edit: I take it it's showing this because the number of pages it could free ("nr") is negative. Which is presumably a bad thing. I found patches for newer kernels that display a more useful message to this effect. Still not sure what this means though, or what I need to do about it.

share|improve this question
up vote 3 down vote accepted

Your message is generated by the slab allocator, the mechanism used by the Linux kernel to manage the portion of memory it needs for itself (not for user space processes). Originally it was written by Jeff Bonwick for Solaris, and it's probably easiest to understand by reading Bonwick(94) (PDF).

If you are wondering about the name, in his blog Bonwick eventually revealed the story behind it.

When you're looking at the Linux specifics, the article Anatomy of the Linux slab allocator (link currently dead, see for a copy) should cover that. If you want to understand management of user-space memory as well, Mel Gorman, Understanding the Linux Virtual Memory Manager gives even more detail.

For German speaking readers, there's an excellent introduction in the German Wikipedia Article on the slab allocator.

share|improve this answer
Fascinating links, thank you! I especially enjoyed reading about "grab a slab". So I take it the messages I'm seeing indicate normal activity, but any ideas why it's showing up now? I've never seen it before. – Steve Kehlet Jun 8 '12 at 20:25

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.