Forum OpenACS Q&A: Response to Webmail progress & problems

Collapse
Posted by Bob Fuller on
Thanks, Dan, for all your help!

Here's the dump (finally):

bash-2.04# !!
     gdb bin/nsd
     GNU gdb 4.18
     Copyright 1998 Free Software Foundation, Inc.
     GDB is free software, covered by the GNU General Public License, and you are
     welcome to change it and/or distribute copies of it under certain conditions.
     Type "show copying" to see the conditions.
     There is absolutely no warranty for GDB.  Type "show warranty" for details.
     This GDB was configured as "i386-suse-linux"...
     (gdb) set args -fkt nsd.tcl -u nsadmin -g nsadmin
     (gdb) run
     Starting program: /usr/local/aolserver/bin/nsd -fkt nsd.tcl -u nsadmin -g nsadmin
     [14/Feb/2001:23:18:24][8811.1024][-main-] Notice: nsd.tcl: starting to read config file...

                                                ...
     [14/Feb/2001:23:21:56][8850.1024][-main-] Notice: ModuleInit: Java Module ENABLED
     [New Thread 8855]
     [Switching to Thread 8855]
     [New Thread 8856]

                                                ...
     [14/Feb/2001:23:21:57][8850.1024][-main-] Notice: ModuleInit: JVM init succeeded!
     [14/Feb/2001:23:22:15][8850.6151][-conn0-] Notice: Ns_PgOpenDb(postgres):  Open
     ned connection to localhost::ruchirasala.
     [14/Feb/2001:23:22:15][8850.6151][-conn0-] Notice: Querying '
             select user_id, token, secure_token,
                    last_ip, last_hit from sec_sessions
             where session_id = 361;'
     [14/Feb/2001:23:22:15][8850.6151][-conn0-] Notice: dbinit: sql(localhost::ruchi
     rasala): '
             select user_id, token, secure_token,
                    last_ip, last_hit from sec_sessions
             where session_id = 361
         '

     [Switching to Thread 8865]

     Program received signal SIGSEGV, Segmentation fault.
     0x4027aca6 in sysThreadStackBase ()
         at ../../../../src/linux/java/native_threads/src/threads_md.c:8787      ../../../../src/linux/java/native_threads/src/threads_md.c: No such file or directory.
     (gdb)
      (gdb) thread apply all bt
      
     Thread 9 (Thread 8867):
     #0  0x400f171e in select () from /lib/libc.so.6
     #1  0x80ed330 in __DTOR_END__ ()
     #2  0x80d094a in NsThreadMain (arg=0x86dd448) at thread.c:241
     #3  0x4002bf93 in pthread_start_thread (arg=0xbebffe40) at manager.c:241
      
     Thread 8 (Thread 8865):
     #0  0x4027aca6 in sysThreadStackBase ()
         at ../../../../src/linux/java/native_threads/src/threads_md.c:87
     #1  0x40266a99 in invoke_FindClass (env=0x402909d4,
         name=0x86aada8 "MessageComposer")
         at ../../../../src/share/java/runtime/jni.c:2855
     #2  0x401a6fed in NsJava_JavaEvalCmd ()
        from /usr/local/aolserver/bin/libnsjava.so
     #3  0x8093945 in Tcl_review (interp=0x84f9e18,
         cmd=0x86abdd8 "

    set tmpfile [ns_mktemp "[ns_info pageroot]/webmail/tmp/.wm_msgXXXXXX"]

    # nsjava available at http://nsjava.sourceforge.net
    ns_java MessageComposer::compose_message $outgoing_msg_id $tmp"...)
         at ./../generic/tclBasic.c:1397
     #4  0x80c26f1 in Tcl_UplevelCmd (dummy=0x0, interp=0x84f9e18, argc=1,
         argv=0xbedfe7e0) at ./../generic/tclProc.c:302
     #5  0x8093945 in Tcl_review (interp=0x84f9e18,
         cmd=0xbedfea12 "ns_db dml $db "begin transaction"
", ' ' , "uplevel $body
", ' ' , "ns_db dml $db "end transaction"") at ./../generic/tclBasic.c:1397
     #6  0x8094c9a in Tcl_CatchCmd (dummy=0x0, interp=0x84f9e18, argc=3,
                         argv=0xbedfe9cc) at ./../generic/tclCmdAH.c:233
     #7  0x8093945 in Tcl_review (interp=0x84f9e18,
         cmd=0x85eb148 "catch {ns_db dml $db "begin transaction"
", ' ' , "uplevel $body
", ' ' , "ns_db dml $db "end transaction"} errmsg] {
	ns_log Notice "error: $errmsg"
        ns_db dml $db "abort transaction"...) at ./../generic/tclBasic.c:1397
     #8  0x80be0dc in TclParseNestedCmd (interp=0x84f9e18,
         string=0x85eb148 "catch {ns_db dml $db "begin transaction"
", ' ' , "uplevel $body
", ' ' , "ns_db dml $db "end transaction"} errmsg] {
	ns_log Notice "error: $errmsg"
        ns_db dml
     $db "abort transaction"..., flags=0, termPtr=0xbedfec38, pvPtr=0xbedfec88)
         at ./../generic/tclParse.c:428
     #9  0x80be595 in TclParseWords (interp=0x84f9e18,
         string=0x85eb144 "if [catch {ns_db dml $db "begin transaction"
", ' ' , "uplevel $body
", ' ' , "ns_db dml $db "end transaction"} errmsg] {
	ns_log Notice "error: $errmsg"
        ns_db
     dml $db "abort transac"..., flags=0, maxWords=8, termPtr=0xbedfec38,
         argcPtr=0xbedfec28, argv=0xbedfec5c, pvPtr=0xbedfec88)
         at ./../generic/tclParse.c:705
     #10 0x8093449 in Tcl_review (interp=0x84f9e18,
         cmd=0x85eb108 "
    upvar errmsg errmsg
    global errorInfo errorCode

        if [catch {ns_db dml $db "begin transaction"
", ' ' , "uplevel $body
", ' ' , "ns_db dml $db "end transaction"} errmsg] {
	ns_log "...) at ./../generic/tclBasic.c:1284
     #11 0x80c2a74 in InterpProc (clientData=0x85eb080, interp=0x84f9e18, argc=0,
         argv=0xbedfef0c) at ./../generic/tclProc.c:494
     #12 0x8093945 in Tcl_review (interp=0x84f9e18,
                               cmd=0x86a8d10 "# /webmail/message-send-3.tcl
# by jsc@arsdigita.com (2000-03-01)

# Send the email.

ad_page_variables {{response_to_msg_id ""} outgoing_msg_id}


set user_id [ad_verify_and_get_user_id]
set db [ns_d"...)
         at ./../generic/tclBasic.c:1397
     #13 0x80ba5b0 in Tcl_EvalFile (interp=0x84f9e18,
         fileName=0xbedff373 "/web/ruchirasala/www/webmail/message-send-3.tcl")
         at ./../generic/tclIOUtil.c:415
     #14 0x809ca65 in Tcl_SourceCmd (dummy=0x0, interp=0x84f9e18, argc=2,
         argv=0xbedff32c) at ./../generic/tclCmdMZ.c:1009
     #15 0x8093945 in Tcl_review (interp=0x84f9e18,
         cmd=0xbedff584 "
		source $script
	") at ./../generic/tclBasic.c:1397
     #16 0x8097d9d in Tcl_IfCmd (dummy=0x0, interp=0x84f9e18, argc=5,
         argv=0xbedff51c) at ./../generic/tclCmdIL.c:167
     #17 0x8093945 in Tcl_review (interp=0x84f9e18,
         cmd=0x86400d0 "
	set script [ns_url2file [ns_conn url $conn]]
	if ![file exists $script] {
		ns_returnnotfound $conn
	} else {
		source $script
	}
") at ./../generic/tclBasic.c:1397
     #18 0x80c2a74 in InterpProc (clientData=0x8640038, interp=0x84f9e18, argc=0,
         argv=0xbedff7cc) at ./../generic/tclProc.c:494
     #19 0x8093945 in Tcl_review (interp=0x84f9e18,
         cmd=0xbedff940 "ns_sourceproc cns2 {}") at ./../generic/tclBasic.c:1397
     #20 0x8093ed9 in Tcl_Globalreview (interp=0x84f9e18,
         command=0xbedff940 "ns_sourceproc cns2 {}")
         at ./../generic/tclBasic.c:1746
     #21 0x80844e9 in TclDoOp (arg=0x81c07c0, conn=0x8389518) at tclop.c:590
     #22 0x8072765 in Ns_ConnRunRequest (conn=0x8389518) at op.c:196
     #23 0x80791ae in ConnRun (connPtr=0x8389518) at serv.c:810
                                 #24 0x8078ade in NsConnThread (arg=0x84ff100) at serv.c:609
     #25 0x80d094a in NsThreadMain (arg=0x8538028) at thread.c:241
     #26 0x4002bf93 in pthread_start_thread (arg=0xbedffe40) at manager.c:241
      
     Thread 7 (Thread 8858):
     #0  0x400f171e in select () from /lib/libc.so.6
     #1  0x4001f8d8 in Ns_ModuleVersion () from /usr/local/aolserver/bin/nssock.so
     #2  0x80d094a in NsThreadMain (arg=0x8366aa0) at thread.c:241
     #3  0x4002bf93 in pthread_start_thread (arg=0xbefffe40) at manager.c:241
      
     Thread 6 (Thread 8857):
     #0  0x40074b7e in sigsuspend () at ../sysdeps/unix/sysv/linux/sigsuspend.c:59
     #1  0x4002e2d0 in __pthread_wait_for_restart_signal (self=0xbf1ffe40)
         at pthread.c:793
     #2  0x4002f474 in __new_sem_wait (sem=0x40292130) at restart.h:26
     #3  0x4027bf51 in sqh ()
         at ../../../../src/linux/java/native_threads/src/interrupt_md.c:232
     #4  0x4027ad8c in jdk_start (tid_=0x815b208)
         at ../../../../src/linux/java/native_threads/src/threads_md.c:446
     #5  0x4002bf93 in pthread_start_thread (arg=0xbf1ffe40) at manager.c:241
      
     Thread 5 (Thread 8856):
     #0  0x40074b7e in sigsuspend () at ../sysdeps/unix/sysv/linux/sigsuspend.c:59
     #1  0x4002e2d0 in __pthread_wait_for_restart_signal (self=0xbf3ffe40)
         at pthread.c:793
     #2  0x4002ad40 in pthread_cond_wait () at condvar.c:72
     #3  0x4027ba0b in condvarWait ()
                     at ../../../../src/linux/java/native_threads/src/condvar_md.c:194
     #4  0x4027a6fb in sysMonitorWait ()
         at ../../../../src/linux/java/native_threads/src/monitor_md.c:127
     #5  0x4025bfc4 in finalizer_loop (tid=0x40653088)
         at ../../../../src/share/java/runtime/finalize.c:276
     #6  0x4027ad8c in jdk_start (tid_=0x815b0c8)
         at ../../../../src/linux/java/native_threads/src/threads_md.c:446
     #7  0x4002bf93 in pthread_start_thread (arg=0xbf3ffe40) at manager.c:241
      
     Thread 4 (Thread 8855):
     #0  0x400d7391 in nanosleep () from /lib/libc.so.6
     #1  0x400d731b in __sleep (seconds=1) at ../sysdeps/unix/sysv/linux/sleep.c:82
     #2  0x4019ffbc in NsJava_StartJvm ()
        from /usr/local/aolserver/bin/libnsjava.so
     #3  0x80d094a in NsThreadMain (arg=0x81118f0) at thread.c:241
     #4  0x4002bf93 in pthread_start_thread (arg=0xbf5ffe40) at manager.c:241
      
     Thread 3 (Thread 8854):
     #0  0x400d7391 in nanosleep () from /lib/libc.so.6
     #1  0x4002b3e6 in pthread_cond_timedwait_relative_new (cond=0x80f9658,
         mutex=0x80fe2b0, abstime=0xbf7ffcec) at condvar.c:318
     #2  0x4002b53a in pthread_cond_timedwait () at condvar.c:375
     #3  0x80d35fb in Ns_CondTimedWait (condPtr=0x80ee358, mutexPtr=0x80ee354,
         timePtr=0xbf7ffd30) at pthread.cpp:525
     #4  0x80779cf in SchedThread (ignored=0x0) at sched.c:789
     #5  0x80d094a in NsThreadMain (arg=0x80ff290) at thread.c:241
     #6  0x4002bf93 in pthread_start_thread (arg=0xbf7ffe40) at manager.c:241
      
     Thread 2 (Thread 8850 (initial thread)):
     #0  0x40074b7e in sigsuspend () at ../sysdeps/unix/sysv/linux/sigsuspend.c:59
     #1  0x4002e9e3 in sigwait () at signals.c:169
     #2  0x80d2456 in ns_sigwait (set=0xbfffe2cc, sig=0xbfffe2c4) at signal.c:87
     #3  0x808eede in NsHandleSignals () at unix.c:158
     #4  0x8071c62 in Ns_Main (argc=7, argv=0xbffff654,
         initProc=0x806eda0 ) at nsmain.c:667
     #5  0x806ed8f in main (argc=7, argv=0xbffff654) at main.c:64
      
     Thread 1 (Thread 8853 (manager thread)):
     #0  0x400effdd in poll () at ../sysdeps/unix/sysv/linux/poll.c:55
     #1  0x4002bc9a in __pthread_manager (arg=0x9) at manager.c:128
     0x4027aca6      87      in ../../../../src/linux/java/native_threads/src/threads_md.c
     (gdb)

I'm also going to try your suggestion of converting to _v3. Possibly tonight, if I have time.