Fast expiry_sleep causing panics

Jeremiah Jordan JEREMIAH.JORDAN at
Sun Jun 3 10:51:50 CEST 2012

We were having an issue with SMA.Transient.g_alloc growing unbounded because we were getting stuff into it faster then the expiry thread could remove it, so we turned down the expiry_sleep.  With expiry_sleep at 0.02 it keeps up with the Transient expiring such that it doesn't grow unbounded, but every 10 minutes or so we get the following panic:

Last panic at: Sun, 03 Jun 2012 08:43:09 GMT
Assert error in oc_getobj(), cache.h line 452:
  Condition((oc->flags & (1<<1)) == 0) not true.
thread = (cache-timeout)
ident = Linux,2.6.18-308.4.1.el5,x86_64,-smalloc,-smalloc,-hcritbit,epoll
  0x42c7a6: /usr/sbin/varnishd [0x42c7a6]
  0x420a35: /usr/sbin/varnishd [0x420a35]
  0x42ebac: /usr/sbin/varnishd [0x42ebac]
  0x3a9de0677d: /lib64/ [0x3a9de0677d]
  0x3a9cad325d: /lib64/ [0x3a9cad325d]

varnish> expiry_sleep 
expiry_sleep               0.020000 [seconds]
                           Default is 1
                           How long the expiry thread sleeps when there is
                           nothing for it to do.


If I set expiry_sleep any higher, it doesn't keep up and Transient store acts basically as a slow memory leak.

-Jeremiah Jordan

More information about the varnish-bugs mailing list