[Varnish] #170: Segmentation violation in HTC_Read at cache_httpconn.c:195

Varnish varnish-bugs at projects.linpro.no
Sun Oct 21 16:47:08 CEST 2007


#170: Segmentation violation in HTC_Read at cache_httpconn.c:195
--------------------------------+-------------------------------------------
 Reporter:  anders              |        Owner:  phk  
     Type:  defect              |       Status:  new  
 Priority:  normal              |    Milestone:       
Component:  varnishd            |      Version:  trunk
 Severity:  normal              |   Resolution:       
 Keywords:  varnishd core dump  |  
--------------------------------+-------------------------------------------
Comment (by anders):

 This happens also with trunk/2096 including patches for ticket 168
 (changeset r2153) and ticket 164 (changeset 2151):

 {{{
 Program received signal SIGSEGV, Segmentation fault.
 [Switching to Thread 0x2d83dcdca0 (LWP 100612)]
 0x0000000800c97ff6 in memcpy () from /lib/libc.so.7
 (gdb) bt
 #0  0x0000000800c97ff6 in memcpy () from /lib/libc.so.7
 #1  0x00000000004173c3 in HTC_Read (htc=0x7fffd389b990, d=0x898036000,
     len=1904) at cache_httpconn.c:182
 #2  0x000000000041169c in fetch_straight (sp=0x2d8415b008,
 htc=0x7fffd389b990,
     b=0x2d8341d3aa "1904") at cache_fetch.c:72
 #3  0x0000000000412380 in Fetch (sp=0x2d8415b008) at cache_fetch.c:331
 #4  0x000000000040ed02 in cnt_fetch (sp=0x2d8415b008) at
 cache_center.c:301
 #5  0x000000000041006c in CNT_Session (sp=0x2d8415b008) at steps.h:40
 #6  0x0000000000417d7d in wrk_do_one (w=0x7fffd389dae0) at
 cache_pool.c:193
 #7  0x0000000000418227 in wrk_thread (priv=0x800e11200) at
 cache_pool.c:245
 #8  0x00000008009929a8 in pthread_getprio () from /lib/libthr.so.3
 #9  0x00007fffd369e000 in ?? ()
 Error accessing memory address 0x7fffd389e000: Bad address.
 (gdb) frame 1
 #1  0x00000000004173c3 in HTC_Read (htc=0x7fffd389b990, d=0x898036000,
     len=1904) at cache_httpconn.c:182
 182                     memcpy(p, htc->pipeline.b, l);
 (gdb) print htc
 $1 = (struct http_conn *) 0x7fffd389b990
 (gdb) print *htc
 $2 = {magic = 1041886673, fd = 22, ws = 0x2d8341d018, rxbuf = {
     b = 0x2d8341d280 "HTTP/1.1",
     e = 0x2d8341d3de "\n\n\n\n<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML
 1.0 Transitional//EN\"
 \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n<html
 xmlns=\"http://www.w3.org/1999/xhtml\">\n<head>\n    <!------ OAS SETUP
 "...}, pipeline = {
     b = 0x2d8341d3de "\n\n\n\n<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML
 1.0 Transitional//EN\"
 \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n<html
 xmlns=\"http://www.w3.org/1999/xhtml\">\n<head>\n    <!------ OAS SETUP
 "..., e = 0x2d8341db4e ""}}
 }}}

 This was done with gdb attached to the varnish child process this time.

-- 
Ticket URL: <http://varnish.projects.linpro.no/ticket/170#comment:2>
Varnish <http://varnish.projects.linpro.no/>
The Varnish HTTP Accelerator


More information about the varnish-bugs mailing list