<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Sep 6, 2016 at 1:55 AM, Olivier <span dir="ltr"><<a href="mailto:oza.4h07@gmail.com" target="_blank">oza.4h07@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><div><div><div><div><div><div><div>Hello,<br><br></div>After testing <span>"pkill -SEGV -f /usr/sbin/asterisk" on Debian Jessie platform, I've got several questions :<br><br><br></span></div><span>1.  When I issue a "cd /tmp; asterisk -cvvvvvvvvvvvg -U asterisk -G asterisk" command, and then issue a "pkill -SEGV asterisk" command,<br></span></div><span>I can read on Asterisk console:<br>*CLI> Segmentation error (core dumped)<br></span></div><span>(*) I translated into english the exact output I got.<br><br></span></div><div><span>I see a /tmp/core file exists.<br></span></div><div><span><br></span></div><span>My asterisk.conf includes:<br>full = verbose,notice,warning,error,<wbr>debug<br><br></span></div><span>After Asterisk's stop, my /var/log:asterisk/full doesn't include any mention to Segmentation error.<br></span></div><div><span>I cannot find anything in dmesg, /var/log/messages or /var/log/kern.log as I did when a real segmentation fault occurred on production system.<br></span></div><div><span><br></span></div><span>I would expect Asterisk to log something.<br></span></div><div><span>Is this expected behaviour ?<br></span></div></div></blockquote><div><br></div><div>Yes.  Asterisk can't really log anything when it ends abruptly because of critical signals like SEGV and since it was user initiated, rather than an actual SEGV, there won't be a message in the kernel log buffer.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><span><br><br>2. </span><span>When I issue a "cd /tmp; systemctl start asterisk" command, and then issue a "pkill
 -SEGV asterisk" command,<br></span><span>I can read on Asterisk console:<br>Disconnected from Asterisk server<br>Asterisk cleanly ending (0).<br>Executing last minute cleanups<br><br></span></div><span></span><div><div><div><div><div><span>I cannot find any core file anyware.<br><br></span></div><div><span>File </span><span>/var/log:asterisk/full doesn't include any mention to Segmentation error.<br><br></span></div><div><span>Where should core file be created when Asterisk is run as a daemon by asterisk user and group ?<br></span></div><div><span>Is there a setting I can use to specify the directory used (so that we can make sure appropriate ownership is set) ?<br></span></div></div></div></div></div></div></blockquote><div><br></div><div>"$ sysctl kernel.core_pattern" will show you where core files are written.  For Asterisk to produce the core file, it has to be started with the '-g' option so make sure your asterisk.service file is adding the option.  </div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><div><div><div><div><span><br></span></div><div><span>Cheers<br></span></div><div><span><br> </span></div></div></div></div></div></div><div class="gmail-HOEnZb"><div class="gmail-h5"><div class="gmail_extra"><br><div class="gmail_quote">2016-09-05 13:36 GMT+02:00 Olivier <span dir="ltr"><<a href="mailto:oza.4h07@gmail.com" target="_blank">oza.4h07@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><span>2016-09-02 20:40 GMT+02:00 George Joseph <span dir="ltr"><<a href="mailto:gjoseph@digium.com" target="_blank">gjoseph@digium.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><span>On Fri, Sep 2, 2016 at 9:34 AM, Olivier <span dir="ltr"><<a href="mailto:oza.4h07@gmail.com" target="_blank">oza.4h07@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><div><div>Hello,<br><br></div>I had a recent case where Asterisk stopped due to a segfault.<br></div>This reminded me that being sure that whenever such issue occurs, it's useful to have a core file or various data at hand to analyze and exchange with support teams.<br><br></div><div>How can you double check a running Asterisk system would produce such data if a segfault arrises ?<br></div><div><br>1. To my knowledge, no tool exists for this. Is it correct ?<br></div><div>2. If such tool do not exist, what would you say about something like "core stop panic", "core stop segfault" or whatever ?<br></div></div></blockquote><div><br></div><div><br></div></span><div>How about just running "pkill -SEGV -f /usr/sbin/asterisk" from the shell?</div></div></div></div></blockquote></span><div><br>It seems to comply to what I'm after.<br></div><div>Thank you very for sharing this here.<br><br></div><div><div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div>Works for me.</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><br></div><div>Best Regards<br></div><div><br><br></div></div>
<br>--<br>
______________________________<wbr>______________________________<wbr>_________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" rel="noreferrer" target="_blank">http://www.api-digital.com</a> --<br>
<br>
Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016<br>
      <a href="http://www.asterisk.org/community/astricon-user-conference" rel="noreferrer" target="_blank">http://www.asterisk.org/commun<wbr>ity/astricon-user-conference</a><br>
<br>
New to Asterisk? Start here:<br>
      <a href="https://wiki.asterisk.org/wiki/display/AST/Getting+Started" rel="noreferrer" target="_blank">https://wiki.asterisk.org/wiki<wbr>/display/AST/Getting+Started</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
   <a href="http://lists.digium.com/mailman/listinfo/asterisk-users" rel="noreferrer" target="_blank">http://lists.digium.com/mailm<wbr>an/listinfo/asterisk-users</a><span><font color="#888888"><br></font></span></blockquote></div><span><font color="#888888"><br><br clear="all"><div><br></div>-- <br><div><div dir="ltr"><span style="font-size:12.8px">George Joseph</span><br style="font-size:12.8px"><span style="font-size:12.8px">Digium, Inc. | Software Developer</span><span style="font-size:12.8px"><br>445 Jan Davis Drive NW - Huntsville, AL 35806 - US<br></span><span style="font-size:12.8px">Check us out at: </span><a href="http://www.digium.com/" rel="noreferrer" style="color:rgb(17,85,204);font-size:12.8px" target="_blank">www.digium.com</a><span style="font-size:12.8px"> & </span><a href="http://www.asterisk.org/" rel="noreferrer" style="color:rgb(17,85,204);font-size:12.8px" target="_blank">www.aster<wbr>isk.org</a><br><div><br></div></div></div>
</font></span></div></div>
<br>--<br>
______________________________<wbr>______________________________<wbr>_________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" rel="noreferrer" target="_blank">http://www.api-digital.com</a> --<br>
<br>
Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016<br>
      <a href="http://www.asterisk.org/community/astricon-user-conference" rel="noreferrer" target="_blank">http://www.asterisk.org/commun<wbr>ity/astricon-user-conference</a><br>
<br>
New to Asterisk? Start here:<br>
      <a href="https://wiki.asterisk.org/wiki/display/AST/Getting+Started" rel="noreferrer" target="_blank">https://wiki.asterisk.org/wiki<wbr>/display/AST/Getting+Started</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
   <a href="http://lists.digium.com/mailman/listinfo/asterisk-users" rel="noreferrer" target="_blank">http://lists.digium.com/mailm<wbr>an/listinfo/asterisk-users</a><br></blockquote></div></div></div><br></div></div>
</blockquote></div><br></div>
</div></div><br>--<br>
______________________________<wbr>______________________________<wbr>_________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" rel="noreferrer" target="_blank">http://www.api-digital.com</a> --<br>
<br>
Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016<br>
      <a href="http://www.asterisk.org/community/astricon-user-conference" rel="noreferrer" target="_blank">http://www.asterisk.org/<wbr>community/astricon-user-<wbr>conference</a><br>
<br>
New to Asterisk? Start here:<br>
      <a href="https://wiki.asterisk.org/wiki/display/AST/Getting+Started" rel="noreferrer" target="_blank">https://wiki.asterisk.org/<wbr>wiki/display/AST/Getting+<wbr>Started</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
   <a href="http://lists.digium.com/mailman/listinfo/asterisk-users" rel="noreferrer" target="_blank">http://lists.digium.com/<wbr>mailman/listinfo/asterisk-<wbr>users</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><span style="font-size:12.8px">George Joseph</span><br style="font-size:12.8px"><span style="font-size:12.8px">Digium, Inc. | Software Developer</span><span style="font-size:12.8px"><br>445 Jan Davis Drive NW - Huntsville, AL 35806 - US<br></span><span style="font-size:12.8px">Check us out at: </span><a href="http://www.digium.com/" rel="noreferrer" style="color:rgb(17,85,204);font-size:12.8px" target="_blank">www.digium.com</a><span style="font-size:12.8px"> & </span><a href="http://www.asterisk.org/" rel="noreferrer" style="color:rgb(17,85,204);font-size:12.8px" target="_blank">www.asterisk.org</a><br><div><br></div></div></div>
</div></div>