View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0001908 | GNUnet | core service | public | 2011-11-16 17:21 | 2011-11-30 18:38 |
| Reporter | LRN | Assigned To | Christian Grothoff | ||
| Priority | urgent | Severity | crash | Reproducibility | sometimes |
| Status | closed | Resolution | fixed | ||
| Product Version | Git master | ||||
| Target Version | 0.9.0 | Fixed in Version | 0.9.0 | ||
| Summary | 0001908: Crash in core service, GNUNET_CONTAINER_multihashmap_contains() fails | ||||
| Description | r18174 crashinfo9.txt contains backtrace and some variable states that might be relevant. Had this crash twice in ~4 testruns. | ||||
| Additional Information | Attaching to process 10868 [New Thread 10868.0x2f10] [New Thread 10868.0xc3c] [New Thread 10868.0x31f8] [New Thread 10868.0x2930] Reading symbols from d:\progs\gnunet\bin\gnunet-service-core.exe...done. [Switching to Thread 10868.0x2930] Continuing. Program received signal SIGTRAP, Trace/breakpoint trap. [Switching to Thread 10868.0x2f10] 0x772515ee in ntdll!LdrQueryProcessModuleInformation () from E:\Windows\SysWOW64\ntdll.dll [Switching to thread 1 (Thread 10868.0x2f10)] #0 0x772515ee in ntdll!LdrQueryProcessModuleInformation () from E:\Windows\SysWOW64\ntdll.dll #0 0x772515ee in ntdll!LdrQueryProcessModuleInformation () from E:\Windows\SysWOW64\ntdll.dll #1 0x772515ee in ntdll!LdrQueryProcessModuleInformation () from E:\Windows\SysWOW64\ntdll.dll #2 0x7724015e in ntdll!LdrFindResource_U () from E:\Windows\SysWOW64\ntdll.dll #3 0x0027f3a8 in ?? () #4 0x00402f49 in _fu80__skip_log () at gnunet-service-core_clients.c:602 #5 0x0040aa37 in solicit_messages (session=0x1f24660) at gnunet-service-core_sessions.c:445 #6 0x0040abee in _fu416__skip_log () at gnunet-service-core_sessions.c:501 #7 0x0040a4a1 in _fu398__skip_log () at gnunet-service-core_sessions.c:364 #8 0x0040232b in _fu44__skip_log () at gnunet-service-core_clients.c:378 #9 0x624b6e2d in GNUNET_SERVER_inject (server=0x1f0c940, sender=0x1f13bc0, message=0x27fbf0) at server.c:709 #10 0x624b785b in client_message_tokenizer_callback (cls=0x1f0c940, client=0x1f13bc0, message=0x27fbf0) at server.c:931 #11 0x624b8bfa in GNUNET_SERVER_mst_receive (mst=0x1f12dc0, client_identity=0x1f13bc0, buf=0x27fbf0 "", size=88, purge=0, one_shot=-1) at server_mst.c:261 #12 0x624b75b2 in process_incoming (cls=0x1f13bc0, buf=0x27fbf0, available=88, addr=0x1f11140, addrlen=28, errCode=0) at server.c:860 #13 0x6248e33f in receive_ready (cls=0x1f13a08, tc=0x28fc90) at connection.c:1193 #14 0x624b3b9b in run_ready (rs=0x1f0e0e8, ws=0x1f0e200) at scheduler.c:684 #15 0x624b42e3 in GNUNET_SCHEDULER_run (task=0x624be19c <service_task>, task_cls=0x28fe28) at scheduler.c:864 #16 0x624bee80 in GNUNET_SERVICE_run (argc=3, argv=0x1f0a2a8, serviceName=0x40e097 "core", opt=GNUNET_SERVICE_OPTION_NONE, task=0x401453 <run>, task_cls=0x0) at service.c:1584 #17 0x004015ac in main (argc=3, argv=0x1f0a2a8) at gnunet-service-core.c:116 (gdb) up 4 #4 0x00402f49 in _fu80__skip_log () at gnunet-service-core_clients.c:602 602 GNUNET_assert (GNUNET_YES == (gdb) l 597 smr.header.type = htons (GNUNET_MESSAGE_TYPE_CORE_SEND_READY); 598 smr.size = htons (car->msize); 599 smr.smr_id = car->smr_id; 600 smr.peer = car->target; 601 #if DEBUG_CONNECTS 602 GNUNET_assert (GNUNET_YES == 603 GNUNET_CONTAINER_multihashmap_contains (c->connectmap, 604 &car-> 605 target.hashPubKey)); 606 #endif (gdb) p *c $1 = {next = 0x0, prev = 0x1f0cbd8, client_handle = 0x1f13bc0, types = 0x1f0cbc8, requests = 0x1f14ba8, connectmap = 0x1f0d588, options = 0, tcnt = 3} (gdb) p *c->connectmap $2 = {map = 0x1f147f8, size = 1, map_length = 16} (gdb) p *c->connectmap->map $3 = (struct MapEntry *) 0x0 (gdb) p car->target $4 = {hashPubKey = {bits = {1412818084, 3863126528, 1350169573, 2311540437, 1034014850, 2483769006, 4130974419, 638545586, 3337313854, 3042942131, 3882409753, 1093488515, 559996766, 3544596907, 2809600301, 2684817734}}} (gdb) | ||||
| Tags | No tags attached. | ||||
| Attached Files | crashinfo9.txt (3,547 bytes)
Attaching to process 10868
[New Thread 10868.0x2f10]
[New Thread 10868.0xc3c]
[New Thread 10868.0x31f8]
[New Thread 10868.0x2930]
Reading symbols from d:\progs\gnunet\bin\gnunet-service-core.exe...done.
[Switching to Thread 10868.0x2930]
Continuing.
Program received signal SIGTRAP, Trace/breakpoint trap.
[Switching to Thread 10868.0x2f10]
0x772515ee in ntdll!LdrQueryProcessModuleInformation () from E:\Windows\SysWOW64\ntdll.dll
[Switching to thread 1 (Thread 10868.0x2f10)]
#0 0x772515ee in ntdll!LdrQueryProcessModuleInformation () from E:\Windows\SysWOW64\ntdll.dll
#0 0x772515ee in ntdll!LdrQueryProcessModuleInformation () from E:\Windows\SysWOW64\ntdll.dll
#1 0x772515ee in ntdll!LdrQueryProcessModuleInformation () from E:\Windows\SysWOW64\ntdll.dll
#2 0x7724015e in ntdll!LdrFindResource_U () from E:\Windows\SysWOW64\ntdll.dll
#3 0x0027f3a8 in ?? ()
#4 0x00402f49 in _fu80__skip_log () at gnunet-service-core_clients.c:602
#5 0x0040aa37 in solicit_messages (session=0x1f24660) at gnunet-service-core_sessions.c:445
#6 0x0040abee in _fu416__skip_log () at gnunet-service-core_sessions.c:501
#7 0x0040a4a1 in _fu398__skip_log () at gnunet-service-core_sessions.c:364
#8 0x0040232b in _fu44__skip_log () at gnunet-service-core_clients.c:378
#9 0x624b6e2d in GNUNET_SERVER_inject (server=0x1f0c940, sender=0x1f13bc0, message=0x27fbf0) at server.c:709
#10 0x624b785b in client_message_tokenizer_callback (cls=0x1f0c940, client=0x1f13bc0, message=0x27fbf0) at server.c:931
#11 0x624b8bfa in GNUNET_SERVER_mst_receive (mst=0x1f12dc0, client_identity=0x1f13bc0, buf=0x27fbf0 "", size=88, purge=0, one_shot=-1)
at server_mst.c:261
#12 0x624b75b2 in process_incoming (cls=0x1f13bc0, buf=0x27fbf0, available=88, addr=0x1f11140, addrlen=28, errCode=0) at server.c:860
#13 0x6248e33f in receive_ready (cls=0x1f13a08, tc=0x28fc90) at connection.c:1193
#14 0x624b3b9b in run_ready (rs=0x1f0e0e8, ws=0x1f0e200) at scheduler.c:684
#15 0x624b42e3 in GNUNET_SCHEDULER_run (task=0x624be19c <service_task>, task_cls=0x28fe28) at scheduler.c:864
#16 0x624bee80 in GNUNET_SERVICE_run (argc=3, argv=0x1f0a2a8, serviceName=0x40e097 "core", opt=GNUNET_SERVICE_OPTION_NONE, task=0x401453 <run>,
task_cls=0x0) at service.c:1584
#17 0x004015ac in main (argc=3, argv=0x1f0a2a8) at gnunet-service-core.c:116
(gdb) up 4
#4 0x00402f49 in _fu80__skip_log () at gnunet-service-core_clients.c:602
602 GNUNET_assert (GNUNET_YES ==
(gdb) l
597 smr.header.type = htons (GNUNET_MESSAGE_TYPE_CORE_SEND_READY);
598 smr.size = htons (car->msize);
599 smr.smr_id = car->smr_id;
600 smr.peer = car->target;
601 #if DEBUG_CONNECTS
602 GNUNET_assert (GNUNET_YES ==
603 GNUNET_CONTAINER_multihashmap_contains (c->connectmap,
604 &car->
605 target.hashPubKey));
606 #endif
(gdb) p *c
$1 = {next = 0x0, prev = 0x1f0cbd8, client_handle = 0x1f13bc0, types = 0x1f0cbc8, requests = 0x1f14ba8, connectmap = 0x1f0d588, options = 0,
tcnt = 3}
(gdb) p *c->connectmap
$2 = {map = 0x1f147f8, size = 1, map_length = 16}
(gdb) p *c->connectmap->map
$3 = (struct MapEntry *) 0x0
(gdb) p car->target
$4 = {hashPubKey = {bits = {1412818084, 3863126528, 1350169573, 2311540437, 1034014850, 2483769006, 4130974419, 638545586, 3337313854, 3042942131,
3882409753, 1093488515, 559996766, 3544596907, 2809600301, 2684817734}}}
(gdb) | ||||
|
|
I think the problem is the usual of core having a disconnect and the client asking for transmission before being notified about the disconnect. Further, this then happens if the core gets a re-connect (but not yet a typemap) in the meantime, so the core is able to initially queue the request with a session again (this explains the "rareness" of the event). Then, the request is "allowed" but rejected by the assertion because the client was told about the disconnect (but not yet about the reconnect). The fix is to really track always (not just for error checking) what the state of the connections wrt to each client is in core and drop the request from the client earlier (in _client.c, not in _session.c). |
|
|
SVN 18181 adds a patch along the lines described in the previous note. |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2011-11-16 17:21 | LRN | New Issue | |
| 2011-11-16 17:21 | LRN | File Added: crashinfo9.txt | |
| 2011-11-17 01:59 | Christian Grothoff | Assigned To | => Christian Grothoff |
| 2011-11-17 01:59 | Christian Grothoff | Status | new => assigned |
| 2011-11-17 01:59 | Christian Grothoff | Priority | normal => urgent |
| 2011-11-17 01:59 | Christian Grothoff | Target Version | => 0.9.0 |
| 2011-11-17 14:21 | Christian Grothoff | Note Added: 0004934 | |
| 2011-11-17 14:22 | Christian Grothoff | Note Added: 0004935 | |
| 2011-11-17 14:22 | Christian Grothoff | Status | assigned => resolved |
| 2011-11-17 14:22 | Christian Grothoff | Fixed in Version | => 0.9.0 |
| 2011-11-17 14:22 | Christian Grothoff | Resolution | open => fixed |
| 2011-11-30 18:38 | Christian Grothoff | Status | resolved => closed |