[OpenSIPS-Users] unable to register to OPENSIP using xlite

Premalatha Kuppan premalatha at ngintech.com
Mon May 31 15:46:39 CEST 2010


Yes, i have checked it. And made changes correspondingly to conenct to the
seperate MySQL server.

Problem is that, first time when OpenSIPS starts up, its taking lot of time
to connect, which u can see from the log.

Later, it gets connected and registration is successful. The point is its
not consistent. (Connection to MySQL is taking lot of time and its not
consistent). After some time it fails.


On Mon, May 31, 2010 at 7:11 PM, Iñaki Baz Castillo <ibc at aliax.net> wrote:

> 2010/5/31 Premalatha Kuppan <premalatha at ngintech.com>:
> > Hi ,
> >
> > I running Mysql server on seperate PC and OPENSIPS on seperate PC. First
> > time when i start opensips, its taking lot of time to connect, appro: 2
> min
> > 50 secs.
>
> Your OpenSIPS CANNTO connect to the remote database, that's all and is
> really visible in the logs. Check that your MySQL is listening in the
> network (not just localhost as it comes by default), check the
> firewall (port 3306) and so on.
>
>
> > So, all registration fails.
> >
> >
> > May 31 09:11:23 204548-4 /usr/local/sbin/opensips[27971]:
> > DBG:db_mysql:db_mysql_connect: opening connection:
> > mysql://xxxx:xxxx@10.140.1.120/opensips
> > May 31 09:13:58 204548-4 /usr/local/sbin/opensips[27971]:
> > DBG:db_mysql:db_mysql_connect: connection type is 10.140.1.120 via TCP/IP
> >
> > After subsquent attempts, User is getting registered. But not consistent.
> >
> > After sometime; i can see in log file,
> > May 31 09:18:48 204548-4 /usr/local/sbin/opensips[28167]:
> > DBG:core:grep_sock_info: checking if port 5060 matches port 5060
> > May 31 09:18:48 204548-4 /usr/local/sbin/opensips[28167]:
> > DBG:auth:check_nonce: comparing
> > [4c03b73c0000000d81a4fdaeb1ffc73590e1f3345dbf9bda] and
> > [4c03b73c0000000d81a4fdaeb1ffc73590e1f3345dbf9bda]
> > May 31 09:18:48 204548-4 /usr/local/sbin/opensips[28167]:
> > DBG:db_mysql:has_stmt_ctx: ctx found for subscriber
> > May 31 09:18:48 204548-4 /usr/local/sbin/opensips[28167]:
> > DBG:db_mysql:db_mysql_do_prepared_query: conn=0x79a9f0 (tail=7973264)
> > MC=0x79cf40
> > May 31 09:18:48 204548-4 /usr/local/sbin/opensips[28167]:
> > DBG:db_mysql:db_mysql_do_prepared_query: set values for the statement run
> > May 31 09:18:48 204548-4 /usr/local/sbin/opensips[28167]:
> > DBG:db_mysql:db_mysql_val2bind: added val (0): len=3; type=254; is_null=0
> > May 31 09:18:48 204548-4 /usr/local/sbin/opensips[28167]:
> > DBG:db_mysql:db_mysql_do_prepared_query: doing BIND_PARAM in...
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[28175]:
> > ERROR:db_mysql:db_mysql_connect: driver error(2003): Can't connect to
> MySQL
> > server on '10.140.1.120' (110)
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[28175]:
> > ERROR:db_mysql:db_mysql_new_connection: initial connect failed
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[28175]:
> > ERROR:core:db_do_init: could not add connection to the pool
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[28175]:
> > ERROR:auth_db:child_init: unable to connect to the database
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[28175]:
> > ERROR:core:init_mod_child: failed to initializing module auth_db, rank 7
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[28175]:
> > ERROR:core:tcp_init_children: init_children failed
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[27971]:
> > ERROR:db_mysql:db_mysql_connect: driver error(2003): Can't connect to
> MySQL
> > server on '10.140.1.120' (110)
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[27971]:
> > ERROR:db_mysql:db_mysql_new_connection: initial connect failed
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[27971]:
> > ERROR:core:db_do_init: could not add connection to the pool
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[27971]:
> > ERROR:usrloc:child_init: child(0): failed to connect to database
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[27971]:
> > ERROR:core:init_mod_child: failed to initializing module usrloc, rank 0
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[27971]:
> > ERROR:core:main_loop: error in init_child for PROC_MAIN
> > May 31 09:19:13 204548-4 /usr/local/sbin/opensips[27971]:
> DBG:xlog:destroy:
> > destroy module...
> >
> >
> > Can any1 help me out, what is missing?
> >
> > Thanks,
> >
> >
> >
> >
> > On Thu, May 27, 2010 at 7:26 PM, Premalatha Kuppan <
> premalatha at ngintech.com>
> > wrote:
> >>
> >> Hi Bogdan,
> >>
> >> Have you seen my opensips.cfg file. Is that correct ?
> >>
> >> Thanks,
> >> Prem
> >>
> >>
> >> On Thu, May 27, 2010 at 7:19 PM, Bogdan-Andrei Iancu
> >> <bogdan at voice-system.ro> wrote:
> >>>
> >>> The reply you posted seams to come from opensips (see the Server
> >>> header)...it seams the REGISTER gets to opensips, but opensips cannot
> >>> forward it (the RURI is not resolvable via DNS).
> >>>
> >>> Maybe you can post the full SIP trace from xlite diagnostic.
> >>>
> >>> Regards,
> >>> Bogdan
> >>>
> >>>
> >>> Premalatha Kuppan wrote:
> >>> > I couldn't see any log at Opensips.
> >>> >
> >>> > I have attached my /usr/local/etc/opensips/opensips.cfg file too.
> >>> > Please tell me whats wrong in that.
> >>> >
> >>> > Also i have set SIP_DOMAIN=opensips (export SIP_DOMAIN=opensips)
> >>> >
> >>> > At xlite: Diagnostic log: i see 476 unresolvable destination
> >>> > RECEIVE TIME: 3545688717
> >>> > RECEIVE << 10.140.1.110:5060 <http://10.140.1.110:5060>
> >>> > SIP/2.0 *476 Unresolvable destination (476/TM) *
> >>> > Via: SIP/2.0/UDP
> >>> >
> >>> > 10.140.1.103:5060
> ;rport=5060;branch=z9hG4bK7D40C114C611CB3CD48AB170D43528DC
> >>> >
> >>> > From: 100 <sip:100 at opensips>;tag=230907502
> >>> > To: 100 <sip:100 at opensips>;tag=65a8173f323da42f74a97c90a2e694f7-b6e3
> >>> > Call-ID: 1A300741EB1C1E842BFF6333D8D43E60 at opensips
> >>> > CSeq: 48981 REGISTER
> >>> > Server: OpenSIPS (1.6.2-tls (x86_64/linux))
> >>> > Content-Length: 0
> >>> >
> >>> > 1. When i start opensips, /etc/init.d/opensips - it shows running.
> But
> >>> > after some time,
> >>> > when i check the status: /etc/init.d/opensips status: I see "opensips
> >>> > dead but subsys locked"
> >>> >
> >>> > 2. Also, when Opensips is running, i tried "*opensipsctl ul show*",
> >>> > iam getting following error,
> >>> > "opensipsctl ul show
> >>> > database engine 'MYSQL' loaded
> >>> > Control engine 'FIFO' loaded
> >>> > entering fifo_cmd ul_dump
> >>> > ERROR: Error opening OpenSIPS's FIFO /tmp/opensips_fifo
> >>> > ERROR: Make sure you have the line 'modparam("mi_fifo", "fifo_name",
> >>> > "/tmp/opensips_fifo")' in your config
> >>> > ERROR: and also have loaded the mi_fifo module.
> >>> > "
> >>> > mi_fifo is.so is available. But opensips_fifo is not available in
> that
> >>> > directory. From where should i copy the opensips_fifo in to /tmp.
> >>> >
> >>> >
> >>> > Can you please help me. I have attached my .cfg file.
> >>> >
> >>> > Thanks,
> >>> > Prem
> >>> >
> >>> > On Wed, May 26, 2010 at 1:04 AM, Bogdan-Andrei Iancu
> >>> > <bogdan at voice-system.ro <mailto:bogdan at voice-system.ro>> wrote:
> >>> >
> >>> >     Do you see the REGISTER getting to your opensips ? what is the
> >>> > reply
> >>> >     send back to xlite?
> >>> >
> >>> >     Regards,
> >>> >     Bogdan
> >>> >
> >>> >     Premalatha Kuppan wrote:
> >>> >     > Thanks, meaning in my config file do i need to uncomment the
> >>> >     following
> >>> >     > (below mail from you) and comment the following lines ?,
> >>> >     > # authenticate the REGISTER requests (uncomment to enable auth)
> >>> >     >         if (!www_authorize("10.140.1.110", "subscriber"))
> >>> >     >         {
> >>> >     >             www_challenge("10.140.1.110", "0");
> >>> >     >             exit;
> >>> >     >         }
> >>> >     >
> >>> >     > I tried this too...But still facing problem.
> >>> >     >
> >>> >     > Probably my set up overview:
> >>> >     > 1.Opensips 1.6.2_tls: i hav etaken the src code and compiled on
> >>> > Red
> >>> >     > Hat Linux 5 enterprise version.
> >>> >     > 2. MySQL is running on seperate PC (10.10.1.2), i created the
> >>> >     MySQL of
> >>> >     > OPENSIPS in that seperate PC (10.10.1.2)
> >>> >     > 3. copied the opensips.init and opensips.default from
> >>> > packaging/rpm
> >>> >     > 4. created user using opensipsctl add 200 200
> >>> >     > 5. corresponding entries updated in MySQL. I have changed the
> >>> >     > SIP_DOMIAN to opensips.
> >>> >     > 6. Now testing call flow through xlite. i hav included in
> >>> > /etc/hosts
> >>> >     > opensips domain IP.
> >>> >     >
> >>> >     > Can you please help me. Where the problem is ? How to fix it. I
> >>> >     > appreciate your kind help.
> >>> >     >
> >>> >     > On Fri, May 21, 2010 at 7:57 PM, Stefano Pisani
> >>> >     > <stefano.pisani at omnianet.it <mailto:stefano.pisani at omnianet.it
> >
> >>> >     <mailto:stefano.pisani at omnianet.it
> >>> >     <mailto:stefano.pisani at omnianet.it>>> wrote:
> >>> >     >
> >>> >     >     you uncommented the wrong lines.
> >>> >     >     you have to uncomment these lines
> >>> >     >
> >>> >     >         # authenticate if from local subscriber (uncomment to
> >>> >     enable auth)
> >>> >     >         # authenticate all initial non-REGISTER request that
> >>> >     pretend to be
> >>> >     >         # generated by local subscriber (domain from FROM URI
> is
> >>> >     local)
> >>> >     >         ##if (!(method=="REGISTER") && from_uri==myself) /*no
> >>> >     >     multidomain version*/
> >>> >     >         ##if (!(method=="REGISTER") && is_from_local())
> >>> >      /*multidomain
> >>> >     >     version*/
> >>> >     >         ##{
> >>> >     >         ##    if (!proxy_authorize("", "subscriber")) {
> >>> >     >         ##        proxy_challenge("", "0");
> >>> >     >         ##        exit;
> >>> >     >         ##    }
> >>> >     >         ##    if (!db_check_from()) {
> >>> >     >         ##        sl_send_reply("403","Forbidden auth ID");
> >>> >     >         ##        exit;
> >>> >     >         ##    }
> >>> >     >         ##
> >>> >     >         ##    consume_credentials();
> >>> >     >         ##    # caller authenticated
> >>> >     >         ##}
> >>> >     >
> >>> >     >
> >>> >     >
> >>> >     >     Il 21/05/2010 16:21, Premalatha Kuppan ha scritto:
> >>> >     >>     I hv attached my opensips.cfg file
> >>> >     >>
> >>> >     >>
> >>> >     >>
> >>> >     >>
> >>> >     >>
> >>> >     >>     On Fri, May 21, 2010 at 7:37 PM, Premalatha Kuppan
> >>> >     >>     <premalatha at ngintech.com <mailto:premalatha at ngintech.com>
> >>> >     <mailto:premalatha at ngintech.com <mailto:premalatha at ngintech.com
> >>>
> >>> >     wrote:
> >>> >     >>
> >>> >     >>         Yes
> >>> >     >>         I created using opensipsctrl add 200 200
> >>> >     >>
> >>> >     >>         But, even in log file i cudn't see nything :(
> >>> >     >>
> >>> >     >>         Iam Opensips running on RHEL, and MySQL on seperate
> >>> >     machine.
> >>> >     >>         Xlite from one Machine A, i changed the /etc/hosts
> also.
> >>> >     >>
> >>> >     >>
> >>> >     >>
> >>> >     >>         On Fri, May 21, 2010 at 7:28 PM, Stefano Pisani
> >>> >     >>         <stefano.pisani at omnianet.it
> >>> >     <mailto:stefano.pisani at omnianet.it>
> >>> >     >>         <mailto:stefano.pisani at omnianet.it
> >>> >     <mailto:stefano.pisani at omnianet.it>>> wrote:
> >>> >     >>
> >>> >     >>             did you create the user?
> >>> >     >>             post your opensips.cfg
> >>> >     >>
> >>> >     >>             s
> >>> >     >>
> >>> >     >>             Il 21/05/2010 15:48, Premalatha Kuppan ha scritto:
> >>> >     >>>             Hi,
> >>> >     >>>
> >>> >     >>>             When i run /etc/int.d/opensips it show running,
> >>> >     >>>
> >>> >     >>>             /etc/init.d/opensips start
> >>> >     >>>             Starting
> >>> >     >>>             opensips:
> >>> >     [  OK  ]
> >>> >     >>>
> >>> >     >>>             But, cudn't register xlite to Opensips. No info
> can
> >>> > be
> >>> >     >>>             found in the log file.
> >>> >     >>>
> >>> >     >>>             Please help.
> >>> >     >>>
> >>> >     >>>             [root at 204548-4 ~]# tail -f /var/log/messages
> >>> >     >>>             May 21 09:34:05 204548-4
> >>> >     /usr/local/sbin/opensips[8938]:
> >>> >     >>>             INFO:sl:mod_init: Initializing StateLess engine
> >>> >     >>>             May 21 09:34:05 204548-4
> >>> >     /usr/local/sbin/opensips[8938]:
> >>> >     >>>             INFO:tm:mod_init: TM - initializing...
> >>> >     >>>             May 21 09:34:05 204548-4
> >>> >     /usr/local/sbin/opensips[8938]:
> >>> >     >>>             INFO:maxfwd:mod_init: initializing...
> >>> >     >>>             May 21 09:34:05 204548-4
> >>> >     /usr/local/sbin/opensips[8938]:
> >>> >     >>>             INFO:usrloc:ul_init_locks: locks array size 512
> >>> >     >>>             May 21 09:34:05 204548-4
> >>> >     /usr/local/sbin/opensips[8938]:
> >>> >     >>>             INFO:registrar:mod_init: initializing...
> >>> >     >>>             May 21 09:34:05 204548-4
> >>> >     /usr/local/sbin/opensips[8938]:
> >>> >     >>>             INFO:textops:mod_init: initializing...
> >>> >     >>>             May 21 09:34:05 204548-4
> >>> >     /usr/local/sbin/opensips[8938]:
> >>> >     >>>             INFO:xlog:mod_init: initializing...
> >>> >     >>>             May 21 09:34:05 204548-4
> >>> >     /usr/local/sbin/opensips[8938]:
> >>> >     >>>             INFO:acc:mod_init: initializing...
> >>> >     >>>             May 21 09:34:05 204548-4
> >>> >     /usr/local/sbin/opensips[8938]:
> >>> >     >>>             INFO:auth:mod_init: initializing...
> >>> >     >>>             May 21 09:34:05 204548-4
> >>> >     /usr/local/sbin/opensips[8938]:
> >>> >     >>>             INFO:auth_db:mod_init: initializing...
> >>> >     >>>
> >>> >     >>>             Thanks,
> >>> >     >>>             Prem
> >>> >     >>>
> >>> >     >>>
> >>> >     >>>             _______________________________________________
> >>> >     >>>             Users mailing list
> >>> >     >>>             Users at lists.opensips.org
> >>> >     <mailto:Users at lists.opensips.org> <mailto:
> Users at lists.opensips.org
> >>> >     <mailto:Users at lists.opensips.org>>
> >>> >     >>>
> >>> >     http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> >>> >     >>>
> >>> >     >>
> >>> >     >>             _______________________________________________
> >>> >     >>             Users mailing list
> >>> >     >>             Users at lists.opensips.org
> >>> >     <mailto:Users at lists.opensips.org> <mailto:
> Users at lists.opensips.org
> >>> >     <mailto:Users at lists.opensips.org>>
> >>> >     >>
> >>> >     http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> >>> >     >>
> >>> >     >>
> >>> >     >>
> >>> >     >>
> >>> >     >>     _______________________________________________
> >>> >     >>     Users mailing list
> >>> >     >>     Users at lists.opensips.org <mailto:Users at lists.opensips.org
> >
> >>> >     <mailto:Users at lists.opensips.org <mailto:
> Users at lists.opensips.org>>
> >>> >     >>     http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> >>> >     >>
> >>> >     >
> >>> >     >     _______________________________________________
> >>> >     >     Users mailing list
> >>> >     >     Users at lists.opensips.org <mailto:Users at lists.opensips.org>
> >>> >     <mailto:Users at lists.opensips.org <mailto:
> Users at lists.opensips.org>>
> >>> >     >     http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> >>> >     >
> >>> >     >
> >>> >     >
> >>> >
> >>> >
> ------------------------------------------------------------------------
> >>> >     >
> >>> >     > _______________________________________________
> >>> >     > Users mailing list
> >>> >     > Users at lists.opensips.org <mailto:Users at lists.opensips.org>
> >>> >     > http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> >>> >     >
> >>> >
> >>> >
> >>> >     --
> >>> >     Bogdan-Andrei Iancu
> >>> >     www.voice-system.ro <http://www.voice-system.ro>
> >>> >
> >>> >
> >>> >     _______________________________________________
> >>> >     Users mailing list
> >>> >     Users at lists.opensips.org <mailto: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
> >>> >
> >>>
> >>>
> >>> --
> >>> Bogdan-Andrei Iancu
> >>> www.voice-system.ro
> >>>
> >>>
> >>> _______________________________________________
> >>> 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
> >
> >
>
>
>
> --
> Iñaki Baz Castillo
> <ibc at aliax.net>
>
> _______________________________________________
> 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/20100531/d2be2dfc/attachment-0001.htm 


More information about the Users mailing list