[OpenSIPS-Users] OPENSIPS+ASTERISK Integration

Premalatha Kuppan premalatha at ngintech.com
Wed Jun 9 09:43:15 CEST 2010


Iam facing one more problem.

Iam running my set up on 64bit processor. Opensips and asterisk on one PC
and Mysql server on seperate PC.

Iam running on RHEL enterprise version.

Problem is that, its taking more than 2 mins to connect to MySQL server when
i start Opensips. Also user is not getting registered. of 10 attmept, only 1
is getting successful. But even this is not consistent.

I have increased connection_timeout in /etc/my.cnf also. But still facing
the same problem.

Any insight ?


Jun  9 03:36:03 204548-4 /usr/local/sbin/opensips[7575]:
DBG:db_mysql:db_mysql_connect: opening connection:
mysql://xxxx:xxxx@MySQLserver/opensips
Jun  9 03:36:03 204548-4 /usr/local/sbin/opensips[7576]:
DBG:core:init_mod_child: type=PROC_TCP_MAIN, rank=-4, module=acc
Jun  9 03:36:03 204548-4 /usr/local/sbin/opensips[7576]:
DBG:core:init_mod_child: type=PROC_TCP_MAIN, rank=-4, module=auth_db
Jun  9 03:36:03 204548-4 /usr/local/sbin/opensips[7576]:
DBG:core:db_do_init: connection 0x79e858 not found in pool
Jun  9 03:36:03 204548-4 /usr/local/sbin/opensips[7576]:
DBG:db_mysql:db_mysql_connect: opening connection:
mysql://xxxx:xxxx@MySQLserver/opensips
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7567]:
ERROR:db_mysql:db_mysql_connect: driver error(2003): Can't connect to MySQL
server on 'MySQLserver' (110)
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7567]:
ERROR:db_mysql:db_mysql_new_connection: initial connect failed
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7567]:
ERROR:core:db_do_init: could not add connection to the pool
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7567]:
ERROR:auth_db:child_init: unable to connect to the database
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7567]:
ERROR:core:init_mod_child: failed to initializing module auth_db, rank 3
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7567]:
ERROR:core:main_loop: init_child failed for UDP listener
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7341]:
ERROR:db_mysql:db_mysql_connect: driver error(2003): Can't connect to MySQL
server on 'MySQL server' (110)
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7341]:
ERROR:db_mysql:db_mysql_new_connection: initial connect failed
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7341]:
ERROR:core:db_do_init: could not add connection to the pool
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7341]:
ERROR:usrloc:child_init: child(0): failed to connect to database
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7341]:
ERROR:core:init_mod_child: failed to initializing module usrloc, rank 0
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7341]:
ERROR:core:main_loop: error in init_child for PROC_MAIN
Jun  9 03:39:12 204548-4 /usr/local/sbin/opensips[7341]: DBG:xlog:destroy:
destroy module...

On Wed, Jun 9, 2010 at 1:04 PM, ram <talk2ram at gmail.com> wrote:

> depends on the design
>
> you can have one point of authenticaion and transaction
>
> Ram
>
>
>
> On Tue, Jun 8, 2010 at 10:59 PM, Premalatha Kuppan <
> premalatha at ngintech.com> wrote:
>
>> Thanks a lot.
>>
>> I have one question. If i route the call to asterisk for IVR ( in my case
>> ivr is to authenticate the user to access the system), who will have the
>> control, meaning who will maintian all the transactions and dailog. Is it
>> opensips/Asterisk ?
>>
>> Thanks,
>> Prem
>>
>>   On Tue, Jun 8, 2010 at 9:50 AM, Gabriel Bermudez <elgabo81 at gmail.com>wrote:
>>
>>> Hi,
>>>
>>> I basically use the load_balancer module to dispatch to different
>>> asterisk servers
>>>
>>> on the main route block after handling auth, registrations, etc
>>>
>>> if(db_is_user_in("Request-URI", "ccivr")) {
>>>          xlog("The call will be redirect to calling card server");
>>>          route(3);
>>> }
>>>
>>> # route for call handled by calling card servers
>>> route[3] {
>>>        # for INVITEs enable some additional helper routes
>>>        if (is_method("INVITE")) {
>>>                t_on_branch("2");
>>>                t_on_reply("2");
>>>                t_on_failure("1");
>>>                if(client_nat_test("15")) {
>>>                        nat_keepalive();
>>>                }
>>>        }
>>>
>>>        # prepare the message for the IVR
>>>
>>>        # select less loaded IVR
>>>        if(!load_balance("1", "ccivr")) {
>>>                xlog("No IVR available !!!");
>>>                sl_send_reply("503", "Service Unavailable");
>>>                exit;
>>>        };
>>>
>>>        if(!t_relay()) {
>>>                sl_reply_error();
>>>                exit;
>>>        }
>>>
>>>        exit;
>>>
>>> }
>>>
>>>
>>> Hope it helps
>>>
>>> Regards,
>>>
>>> 2010/6/8 ram <talk2ram at gmail.com>:
>>>  > I forgot the link
>>> >
>>> > i did this work some time back
>>> >
>>> > Lost the link, google it
>>> >
>>> > Opensips+asterisk+a2b
>>> >
>>> > Ram
>>> >
>>> > On Mon, Jun 7, 2010 at 4:07 PM, Premalatha Kuppan <
>>> premalatha at ngintech.com>
>>> > wrote:
>>> >>
>>> >> Can you pleae guide me how to do this ?
>>> >>
>>> >> On Mon, Jun 7, 2010 at 4:04 PM, Douglas Lane <doug at wd.co.za> wrote:
>>> >>>
>>> >>> Hi Premalatha,
>>> >>>
>>> >>> Perhaps have a look at SEMS for this.
>>> >>>
>>> >>> Thanks
>>> >>> Doug
>>> >>>
>>> >>>
>>> >>> On 2010/06/07 12:30 PM, Premalatha Kuppan wrote:
>>> >>>
>>> >>> Thanks Sebastian.
>>> >>>
>>> >>> I have followed up this link and tried extending the opensips.cfg
>>> file to
>>> >>> route call to Asterisk.
>>> >>>
>>> >>> I doubt/not clear that after IVR (meaning when the user is
>>> authenticated
>>> >>> through IVR) who will handle all the transactions and dialog
>>> (OPENSIPS or
>>> >>> Asterisk ) ?
>>> >>>
>>> >>> I want Opensips to handle all the transactions.
>>> >>>
>>> >>> Any insight on this ?
>>> >>>
>>> >>> Thanks,
>>> >>> Prem
>>> >>>
>>> >>> On Mon, Jun 7, 2010 at 3:15 PM, Schumann Sebastian
>>> >>> <Sebastian.Schumann at t-com.sk> wrote:
>>> >>>>
>>> >>>> Hi Prem
>>> >>>>
>>> >>>> There is a good tutorial at
>>> >>>> http://www.opensips.org/Resources/DocsTutAsterisk It does exactly
>>> what you
>>> >>>> need I assume.
>>> >>>>
>>> >>>> For details in writing and extending basic configuration, you can
>>> find
>>> >>>> also the linked documentation there.
>>> >>>>
>>> >>>> Best regards
>>> >>>> Sebastian
>>> >>>>
>>> >>>> > -----Original Message-----
>>> >>>> > From: users-bounces at lists.opensips.org [mailto:users-
>>> >>>> > bounces at lists.opensips.org] On Behalf Of Premalatha Kuppan
>>> >>>> > Sent: Monday, 07. June 2010 11:35
>>> >>>> > To: OpenSIPS users mailling list
>>> >>>> > Subject: [OpenSIPS-Users] OPENSIPS+ASTERISK Integration
>>> >>>> >
>>> >>>> > Hi,
>>> >>>> >
>>> >>>> > Can anyone guide me in building the Opensips and Asterisk
>>> Integration.
>>> >>>> >
>>> >>>> > I want to Use OpenSIPS as SIP PROXY (i.e all transactions and
>>> dialogs
>>> >>>> > should be
>>> >>>> > handled by Opensips) and Asterisk to do only IVR functionality.
>>> >>>> >
>>> >>>> > I appreciate if anyone can guide me in writing a routing logic
>>> from
>>> >>>> > Opensips to
>>> >>>> > Asterisk for IVR and futher call flow OPENSIPS to handle.
>>> >>>> >
>>> >>>> > Thanks,
>>> >>>> > Prem
>>> >>>> >
>>> >>>>
>>> >>>>
>>> >>>> _______________________________________________
>>> >>>> Users mailing list
>>> >>>> Users at lists.opensips.org
>>> >>>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>> >>>
>>> >>>
>>> >>> _______________________________________________
>>> >>> Users mailing list
>>> >>> Users at lists.opensips.org
>>> >>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>> >>>
>>> >>>
>>> >>> _______________________________________________
>>> >>> Users mailing list
>>> >>> Users at lists.opensips.org
>>> >>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>> >>>
>>> >>
>>> >>
>>> >> _______________________________________________
>>> >> Users mailing list
>>> >> Users at lists.opensips.org
>>> >> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>> >>
>>> >
>>> >
>>> > _______________________________________________
>>> > Users mailing list
>>> > Users at lists.opensips.org
>>> > http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>> >
>>> >
>>>
>>> _______________________________________________
>>> Users mailing list
>>> Users at lists.opensips.org
>>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>>
>>
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.opensips.org
>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>
>>
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.opensips.org/pipermail/users/attachments/20100609/1c30966e/attachment-0001.htm 


More information about the Users mailing list