[asterisk-users] Segmentation fault

John Harragin
Thu, 17 Aug 2023 18:44:32 -0000

You should be able to define multiple data sources. However I'm having my
own issues. I have my dialplan accessing one maria database which is hosted
locally on the asterisk server then logging cdr with odbc adaptive which
connects to maria on a remote machine. This works fine except when the
remote server is out of reach the calls zombie and eventually lead to a
fault. The cli imply that the calls hang on SET(CDR_PROP(disable)=1) which
is ironic since instructing the system not to connect to the cdr server
appears to cause the problem and there may be a defect in the adaptive_odbc
implementation where it somehow still communicates with the server during
the cdr_func(disable). My experimentation suggests that the maria_odbc
driver utilizes a single thread (there are odbc directives to adjust this -
but it seems they have been superseded). Once a cdr hangs, new calls hang
on odbc calls to the local database.

In my case the remote server is 5' away and in the same switch that
Asterisk is plugged into, so it hasn't been critical to fix this - but it
may provide some clues to your situation.

On Thu, Aug 17, 2023 at 11:04 AM Federico <federico at digitalipvoice.com>
wrote:

> I tested this issue with version 13 and version 18.
>
> In res_odbc.conf, if I add a second, new data source like
>
>
>
> [asterisk]
>
> enabled=yes
>
> dsn=asterisk
>
> sanitysql => select 1
>
> isolation => read_committed
>
> username=root
>
> ;password>
> pre-connect => yes
>
> forcecommit => yes
>
> connect_timeout => 10
>
> negative_connection_cache => 0
>
> max_connections =>500
>
>
>
> my odbc.ini
>
> [cdr]
>
> Description = MySQL ODBC Driver Testing
>
> Driver = maria
>
> Socket = /var/run/mysqld/mysqld.sock
>
> User = root
>
> Password >
> Database = public
>
> Option = 3
>
>
>
>
>
> I  get, immediately, segmentation fault.
>
> With only one, it works fine.
>
> Is this by design?
>
>
>
> Philip
>
>
>
>
>
>
> --
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> Check out the new Asterisk community forum at:
> https://community.asterisk.org/
>
> New to Asterisk? Start here:
>       https://wiki.asterisk.org/wiki/display/AST/Getting+Started
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.digium.com/pipermail/asterisk-users/attachments/20230817/8062d56f/attachment.html>