Child panics on OpenSolaris

Paul Wright wrighty+varnishmisc at gmail.com
Wed Feb 17 17:52:26 CET 2010


On 17 February 2010 11:14, Poul-Henning Kamp <phk at phk.freebsd.dk> wrote:
> In message <282e72051002170310g565a26d8s98170fcebb9b2997 at mail.gmail.com>, Paul
> Wright writes:
>>On 17 February 2010 10:57, Poul-Henning Kamp <phk at phk.freebsd.dk> wrote:
>
>>I have pulled the latest revision and can confirm that unlink("/")
>>failed as expected.  I ran it briefly and saw this panic:
>>
>>Child (28554) died signal=3D6
>>Child (28554) Panic message: Assert error in http_copyheader(),
>>cache_http.c line 647:
>>  Condition(n < to->shd) not true.
>
> Sounds like you got too many headers from the backend, if so,
> consider increasing the parameter 'http_headers'

I pulled r4574 with the new TCP_Assert() changes, I increased
http_headers to 128 and it ran like a champ for 25 minutes.  Then a
client made a Range request resulting in a "Partial Content" response
which produced the panic included below.  I've boiled down the request
to a simple curl command that consistently panics the child:

curl -v -H "Range: bytes=0-1" -H "Cookie: foo" http://192.168.0.35/robots.txt

(The cookie header ensures the request is passed through to the
backend. Curl will respond with "Failure when receiving data from the
peer".)

I note that ticket #466 mentions that Varnish doesn't support Range
requests and r3910 should stop such requests passing though - is this
expected behaviour?  Should I stop the backend from generating partial
content responses?  Or should there be a check for such requests and
they should be piped instead of passed?

Paul.

Child (21350) died signal=6
Child (21350) Panic message: Assert error in http_copyheader(),
cache_http.c line 647:
  Condition(n < to->shd) not true.
thread = (cache-worker)
ident = -smalloc,-hcritbit,poll
Backtrace:
  447b2b: /opt/sbin/varnishd'pan_backtrace+0x1b [0x447b2b]
  447e35: /opt/sbin/varnishd'pan_ic+0x1c5 [0x447e35]
  4407e1: /opt/sbin/varnishd'http_copyheader+0x1c1 [0x4407e1]
  442401: /opt/sbin/varnishd'http_FilterFields+0xdc1 [0x442401]
  429c9d: /opt/sbin/varnishd'cnt_fetch+0x11fd [0x429c9d]
  42cf8a: /opt/sbin/varnishd'CNT_Session+0x78a [0x42cf8a]
  44a83f: /opt/sbin/varnishd'wrk_do_cnt_sess+0x1bf [0x44a83f]
  449db2: /opt/sbin/varnishd'wrk_thread_real+0x882 [0x449db2]
  44a365: /opt/sbin/varnishd'wrk_thread+0x135 [0x44a365]
  fffffd7ff653acf5: /lib/amd64/libc.so.1'_thrp_setup+0x8d [0xfffffd7ff653acf5]
sp = 1140e08 {
  fd = 77, id = 77, xid = 133352112,
  client = 66.235.125.136:38373,
  step = STP_FETCH,
  handling = pass,
  err_code = 206, err_reason = (null),
  restarts = 0, esis = 0
  ws = 1140e78 {
    id = "sess",
    {s,f,r,e} = {1142400,+388,0,+65536},
  },
  http[req] = {
    ws = 1140e78[sess]
      "GET",
      "/robots.txt",
      "HTTP/1.1",
      "TE: deflate,gzip;q=0.3",
      "Connection: TE, close",
      "From: robots at pronto.com",
      "Host: www.firebox.com",
      "Range: bytes=0-199999",
      "User-Agent: RedCarpet/1.4 (http://www.pronto.com/robots.html)",
      "Cookie: CFTOKEN=aeed9fb6cc27a0f7-8F680632-1517-0C84-6887BD4A85FF98A8;
CFID=128110309",
      "Cookie2: $Version="1"",
      "X-Forwarded-For: 66.235.125.136",
  },
  worker = fffffd7ff7813d30 {
    ws = fffffd7ff7813e78 {
      id = "wrk",
      {s,f,r,e} = {fffffd7ff7801c40,+528,0,+65536},
    },
    http[bereq] = {
      ws = fffffd7ff7813e78[wrk]
        "GET",
        "/robots.txt",
        "HTTP/1.1",
        "From: robots at pronto.com",
        "Host: www.firebox.com",
        "Range: bytes=0-199999",
        "User-Agent: RedCarpet/1.4 (http://www.pronto.com/robots.html)",
        "Cookie:
CFTOKEN=aeed9fb6cc27a0f7-8F680632-1517-0C84-6887BD4A85FF98A8;
CFID=128110309",
        "Cookie2: $Version="1"",
        "X-Forwarded-For: 66.235.125.136",
        "X-Varnish: 133352112",
    },
    http[beresp] = {
      ws = fffffd7ff7813e78[wrk]
        "HTTP/1.1",
        "206",
        "Partial Content",
        "Date: Wed, 17 Feb 2010 16:25:42 GMT",
        "Server: Apache",
        "Last-Modified: Fri, 11 Dec 2009 18:15:28 GMT",
        "ETag: "19c0073-de-47a77e88b9000"",
        "Accept-Ranges: bytes",
        "Content-Length: 222",
        "Content-Range: bytes 0-221/222",
        "Connection: close",
        "Content-Type: text/plain",
    },
    },
    vcl = {
      srcname = {
        "input",
        "Default",
      },
    },
  obj = 8c1d8a0 {
    xid = 133352112,
    ws = 8c1d8c0 {
      id = "obj",
      {s,f,r,e} = {8c1daa5,8c1daa5,0,+213},
    },
    http[obj] = {
      ws = 8c1d8c0[obj]
        "HTTP/1.1",
        "206",
        "Partial Content",
        "Date: Wed, 17 Feb 2010 16:25:42 GMT",
        "Server: Apache",
        "Last-Modified: Fri, 11 Dec 2009 18:15:28 GMT",
        "ETag: "19c0073-de-47a77e88b9000"",
    },
    len = 0,
    store = {
    },
  },
},


More information about the varnish-misc mailing list