[asterisk-users] Realtime pjsip issues

Bryant Zimmerman BryantZ at zktech.com
Fri Sep 15 10:18:47 CDT 2017


Joshua
  
 We are using MariaDB as the database storage. 
 We have recreated the database tables with alembic. 
  
 Test 1:
  	We enable tables for aors, auths and endpoints only.  	With cache turned 
off the end point registers successfully 	We have no way to get any feed 
back as pjsip show/list returns no objects found. 	pjsip send notify cmd 
endpoint -- does not work as it says there is no endpoint. 	endpoint can 
send a call as it appears to be registered, we have no way to confirm this 
form the console but calls come in.  
  
 Test 2: 
  	We enable cache on the endpoints, auth and aors in the sorcery.conf 	 
		endpoint/cache = 
memory_cache,object_lifetime_stale=600,object_lifetime_maximum=1800,expire_o
n_reload=yes,full_backend_cache=yes 
		auth/cache=memory_cache,expire_on_reload=yes 		aor/cache = 
memory_cache,object_lifetime_stale=1500,object_lifetime_maximum=1800,expire_
on_reload=yes,full_backend_cache=yes 	
	 	    We now get an error: 	 		[2017-09-15 11:02:04] WARNING[3375]: 
res_pjsip_registrar.c:744 registrar_on_rx_request: AOR '6162480909-300' has 
no configured max_contacts. Endpoint '6162480909-300' unable to register 
		The aors entry has the max_contacts set to 1 but the error still occurs.  
	
	 	    pjsip show/list shows the endpoint shows endpoints, aors, auths  but 
registration fails 
  
  Test 3: 
  	We enable cache on the endpoints, auth and aors in the sorcery.conf 	 
		endpoint/cache = 
memory_cache,object_lifetime_stale=600,object_lifetime_maximum=1800,expire_o
n_reload=yes 		auth/cache=memory_cache,expire_on_reload=yes 		aor/cache = 
memory_cache,object_lifetime_stale=1500,object_lifetime_maximum=1800,expire_
on_reload=yes 	
	 	Endpoint registers 	pjsip show/list endpoints works the first time and 
fails there after.  	 	 	 	UBNTU-ROSSI-GUEST*CLI> pjsip show endpoints
 	 Endpoint:  <Endpoint/CID.....................................>  
<State.....>  <Channels.>
	    I/OAuth:  
<AuthId/UserName...........................................................>

	        Aor:  <Aor............................................>  
<MaxContact>
	      Contact:  <Aor/ContactUri..........................> <Hash....> 
<Status> <RTT(ms)..>
	  Transport:  <TransportId........>  <Type>  <cos>  <tos>  
<BindAddress..................>
	   Identify:  
<Identify/Endpoint.........................................................>

	        Match:  <criteria.........................>
	    Channel:  <ChannelId......................................>  
<State.....>  <Time.....>
	        Exten: <DialedExten...........>  CLCID: <ConnectedLineCID.......>
	===========================================================================
===============
 	 Endpoint:  6162480909-300                                       Not in 
use    0 of inf
	     InAuth:  6162480909-300/6162480909-300
	        Aor:  6162480909-300                                     1
	      Contact:  6162480909-300/sip:6162480909-300 at 192.168. 0475d46ff2 
Unknown         nan
	  Transport:  udp-nat                   udp      0      0  0.0.0.0:5060

	Objects found: 1
 	UBNTU-ROSSI-GUEST*CLI> pjsip show endpoints
	No objects found.

	 	pjsip show/list shows the endpoint fails ever time after the first. 

 Test 4: 
  	Test 1: with the addition of the contacts entry as realtime in 
sorcery.conf 	We get error on registration attempt: 	 		[2017-09-15 
11:16:07] WARNING[3591]: res_config_odbc.c:120 custom_prepare: SQL Prepare 
failed! [INSERT INTO ps_contacts (id, via_addr, qualify_timeout, call_id, 
reg_server, path, endpoint, via_port, authenticate_qualify, uri, 
qualify_frequency, user_agent, expiration_time, outbound_proxy) VALUES (?, 
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)] 		[2017-09-15 11:16:07] 
ERROR[3591]: res_pjsip_registrar.c:432 register_aor_core: Unable to bind 
contact 'sip:6162480909-300 at 192.168.201.105:59758' to AOR '6162480909-300' 
	
	 	Registration has failed at this point.  
  
 I can offer the following:
     A dump of the database schema that alembic is creating.
     extconfig.config
     sorcery.conf
  
 Thanks
 Bryant
  

----------------------------------------
 From: "Joshua Colp" <jcolp at digium.com>
Sent: Friday, September 15, 2017 9:56 AM
To: asterisk-users at lists.digium.com
Subject: Re: [asterisk-users] Realtime pjsip issues   
On Fri, Sep 15, 2017, at 10:37 AM, Bryant Zimmerman wrote:
> Joshua
>
> That is the interesting part of it. We took our configs and database
> tables from our working 13.12.2 deployments and tried to use them with
> our
> new 13.17.1 deployments and we are having issues where the tables are 
not
> working. On the new server asterisk keeps saying it can't find the AORS
> entries when we purge the sorcery memory cache it starts finding the 
aors
> but then it says it cant find the auths.
>
> The wired thing is when it says it can't find the aors and auths entries
> it does not show it is looking for the values in the aors and auth 
fields
> from the endpoints tables. It keeps putting the value from the endpoints
> id
> field as the entries it can't find.
>
> One point of note the tables we used and created for pjsip back when we
> setup the 13.12.2 version are not what is currently being created when 
we
> run alembic now.. Also the contact table from alembic creation process
> does
> not work we get insert errors inside of asterisk when contact entry
> attempts are being crated. It shows a number of fields that are not 
there
> in the created tables.
>
> This is the foundation of my issues. I really have to resolve them in
> some
> manner so I can mover forward with getting these new systems into
> production.
> Any assistance is appreciated.

You're really throwing a lot of things in here. Please try to simplify
this first and remove the caching. After that what exactly does it say
it can't find when trying to add a contact? What database is in use? Did
you create the tables fresh from alembic? Upgrade existing? If you
enable debug (debug to console in logger.conf and core set debug 5) does
it show it doing database queries?

As it is right now things haven't been narrowed down enough for me to
give any concrete answer or help.

--
Joshua Colp
Digium, Inc. | Senior Software Developer
445 Jan Davis Drive NW - Huntsville, AL 35806 - US
Check us out at: www.digium.com & www.asterisk.org

--
_____________________________________________________________________
-- 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/20170915/b69ff18b/attachment.html>


More information about the asterisk-users mailing list