Hi,<br><br>yes, you&#39;re totally right, we got the core in other server and I though the fix was included in the code we compiled in this server, but it wasn&#39;t. My fault.<br><br>Now, a very recent copy of the 3.1 git branch is running, Daniel&#39;s patch is included. I&#39;ll keep you informed but it should go fine.<br>
<br>Thanks, and sorry for the misunderstanding, <br><br>Regards,<br>Anton<br><br><br><br><div class="gmail_quote">2011/5/13 Timo Reimann <span dir="ltr">&lt;<a href="mailto:timo.reimann@1und1.de">timo.reimann@1und1.de</a>&gt;</span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hey,<br>
<div><div></div><div class="h5"><br>
<br>
On 13.05.2011 11:11, Timo Reimann wrote:<br>
&gt; On 12.05.2011 15:55, Anton Roman wrote:<br>
&gt;&gt; my answer is inline:<br>
&gt;&gt;<br>
&gt;&gt; 2011/5/12 Timo Reimann &lt;<a href="mailto:timo.reimann@1und1.de">timo.reimann@1und1.de</a><br>
&gt;&gt; &lt;mailto:<a href="mailto:timo.reimann@1und1.de">timo.reimann@1und1.de</a>&gt;&gt;<br>
&gt;&gt;     As to the reason of the segfault, the dialog structure or hash table may<br>
&gt;&gt;     already be gone when unref_dlg() is called. Can you go to stack #0 and<br>
&gt;&gt;     tell us what the value of each of the following data structures is (use<br>
&gt;&gt;     &quot;p &lt;data structure&gt; in gdb):<br>
&gt;&gt;<br>
&gt;&gt;     *dlg<br>
&gt;&gt;     d_table<br>
&gt;&gt;     d_table-&gt;entries<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; Here you have:<br>
&gt;&gt;<br>
&gt;&gt; (gdb) p *dlg<br>
&gt;&gt; $1 = {ref = 793790803, next = 0xa0d4b4f20303032, prev =<br>
&gt;&gt; 0x504953203a616956, h_id = 808333871, h_entry = 1346655535, state =<br>
&gt;&gt; 775174432,<br>
&gt;&gt;   lifetime = 841888562, start_ts = 892219952, dflags = 808794678, sflags<br>
&gt;&gt; = 1648046134, toroute = 1668178290, toroute_name = {<br>
&gt;&gt;     s = 0x62344768397a3d68 &lt;Address 0x62344768397a3d68 out of bounds&gt;,<br>
&gt;&gt; len = 946221643}, from_rr_nb = 1886534457, tl = {<br>
&gt;&gt;     next = 0x72460a0d30363035, prev = 0x6f6e4122203a6d6f, timeout =<br>
&gt;&gt; 1869445486}, callid = {<br>
&gt;&gt;     s = 0x6f6e613a7069733c &lt;Address 0x6f6e613a7069733c out of bounds&gt;,<br>
&gt;&gt; len = 1869445486}, from_uri = {<br>
&gt;&gt;     s = 0x3230322e33322e34 &lt;Address 0x3230322e33322e34 out of bounds&gt;,<br>
&gt;&gt; len = 1043739950}, to_uri = {<br>
&gt;<br>
&gt; [...]<br>
&gt;<br>
&gt; As I suspected, your dialog seems outdated already: The reference count<br>
&gt; is 793790803, and the Call-ID is supposed to have a rough 2 billions<br>
&gt; characters. That&#39;s what I call unique. :)<br>
&gt;<br>
&gt; I could ask you for more details on the dump but it&#39;d probably be<br>
&gt; easiest if I could take a direct (gdb-)look at it. Would you mind<br>
&gt; sending it to me in private (i.e., no CC to the mailing list) to the<br>
&gt; address I am writing from?<br>
<br>
</div></div>I (and Marius -- credits!) digged through your coredump and found a few<br>
curiosities. Before I bug you with the details, let me just say this:<br>
There might be something wrong the dialog reference counter that<br>
determines when a dialog is a to be removed from the hash table. In<br>
fact, your call stack indicates that an unreference operation was<br>
attempted on a hash table which looks empty:<br>
<br>
(gdb) frame 0<br>
<div class="im">#0  unref_dlg (dlg=0x7f08a9f67da8, cnt=1) at dlg_hash.c:598<br>
</div>598             dlg_lock( d_table, d_entry);<br>
<div class="im">(gdb) p *d_table-&gt;entries<br>
</div>$53 = {first = 0x0, last = 0x0, next_id = 1124074261, lock_idx = 0}<br>
<br>
<br>
Looking through the mailing-list archive, I noticed you brought<br>
attention to another reference counter-related bug which Daniel provided<br>
a fix for with commit 2c28a251a. Since you reported that no more issues<br>
appeared with that fixed version, I just backported the patch into 3.1.<br>
However, I can see from your core dump that you are not using a Kamailio<br>
version that includes the fix.<br>
<br>
Before we continue with any bug hunting, could you try a version of<br>
Kamailio that comes with Daniel&#39;s &quot;safer unref of terminated dialogs&quot;<br>
patch? This can be master branch copy or a recent copy of the 3.1 git<br>
branch. I&#39;d suggest the latter so we can ensure that no bleeding-edge<br>
features added to the dialog module distort our analysis.<br>
<br>
Thanks and<br>
<br>
<br>
Cheers,<br>
<font color="#888888"><br>
--Timo<br>
</font></blockquote></div><br>