[asterisk-bugs] [JIRA] (ASTERISK-25891) Crash using ODBC in mysql with heavy usage

Carlos Oliva (JIRA) noreply at issues.asterisk.org
Wed Apr 27 04:32:58 CDT 2016


    [ https://issues.asterisk.org/jira/browse/ASTERISK-25891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=230432#comment-230432 ] 

Carlos Oliva commented on ASTERISK-25891:
-----------------------------------------

According to changelog the differences between 13.8.0 and 13.8.2 are only in pjsip. As I use chan_sip and not pjsip I did not update to 13.8.2 because It will not make any difference on my environment.

Probably the change you mentioned is Change-Id: I37a84def5ea4ddf93868ce8105f39de078297fbf introduced in 13.8.0 revision. This is a huge change of ODBC, it removes connection management inside asterisk and delegate this to ODBC. For this change I must use pooling=yes in odbcinst.ini This change introduces problems if you are using old ODBC mysql drivers or old unixODBC drivers. It produces some problems too as mentioned in ASTERISK-25938 if you try to use functions that needs that consecutive queries use the same connection, as the connections now are delegated completly to unixODBC driver.

As I can read in ASTERISK-25938 this ODBC change is going to be reverted in 13.9.0, but in my environment this change works very well and queries run faster than in 13.7.2 (is difficult to asseverate but is my impression) I can read in the issue that probably this change will be postponed to Asterisk 14

I can confirm the change-Id: I37a84def5ea4ddf93868ce8105f39de078297fbf works well in my environment because I use the latest version of unixODBC and mysql connector (if you use old versions it breaks Asterisk totally) and I don't use functions in consecutive queries that relays to be executed in the same connection.

If you use an Asterisk without this ODBC change (13.7.2 or future 13.9.0) probably you will not need the parameters "Pooling = Yes" and "CPTimeout = 120" in your unixODBC config files.

> Crash using ODBC in mysql with heavy usage
> ------------------------------------------
>
>                 Key: ASTERISK-25891
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-25891
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Resources/res_odbc
>    Affects Versions: 13.8.0
>         Environment: debian jessie 8.4 (KVM virtual machine)
>            Reporter: Carlos Oliva
>            Assignee: Rusty Newton
>         Attachments: backtrace1.txt, backtrace2.txt, backtrace3.txt, bt_libmysql5_7.txt
>
>
> testing release 13.8.0 I found crashes making heavy use of ODBC with mysql. This issue seems to not happen in 13.7.2 release.
> We make a heavy usage of mysql using ODBC, dialplan functions and CEL. The isse seems to happen with 4 or 5 calls using queues, cel logging to mysql and lots of database calls in the dialplan.
>  I think maybe related to Change-Id: I37a84def5ea4ddf93868ce8105f39de078297fbf (res_odbc: Remove connection management) because it directly affects to odbc connection settings. 
> I will attach some backtraces where you can see clearly the issue is related to odbc and libmysqlclient.so.18



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list