[SOLVED] Error register_aor_core: Unable to bind contact


#1

Hello!
Faced the following errors:

[Jul 17 05:49:14] WARNING [13294]: db.c: 332 ast_db_put: Could not execute stat: SQL logic error or missing database
[Jul 17 05:49:14] ERROR [13294]: res_pjsip_registrar.c: 432 register_aor_core: Unable to bind contact ‘sip: 1000@xxx.xxx.xxx.xxx: 19718; ob’ to AOR ‘1000’

At the same registration is correct. Has anyone encountered similar problems? And how they managed to be solved.

[Main](!)
100rel=no
aggregate_mwi=no
disallow=all
allow=alaw,ulaw
allow_overlap=no
direct_media_glare_mitigation=none
direct_media_method=invite
connected_line_method=invite
direct_media=yes
disable_direct_media_on_nat=no
media_address=xxx.xxx.xxx.xxx
bind_rtp_to_media_address=xxx.xxx.xxx.xxx
force_rport=yes
ice_support=no
rtp_ipv6=no
rtp_symmetric=no
send_diversion=yes
send_pai=yes
send_rpid=yes
rpid_immediate=no
timers_min_se=180
timers=yes
timers_sess_expires=1800
transport=Main-transport
type=endpoint
tone_zone=ru
language=ru
rtp_engine=asip
user_eq_phone=yes
sdp_owner=asip
sdp_session=asip
rtp_timeout=900
rtp_timeout_hold=900

[Main-domain-alias]
type=domain_alias
domain=mydomain.com

[Main-transport]
async_operations=1
bind=0.0.0.0
domain=mydomain.com
external_media_address=xxx.xxx.xxx.xxx
external_signaling_address=xxx.xxx.xxx.xxx
external_signaling_port=5060
protocol=udp
type=transport
allow_reload=no
symmetric_transport=no

[Main-system]
timer_t1=500
timer_b=32000
compact_headers=no
threadpool_initial_size=0
threadpool_auto_increment=5
treadpool_idle_timeout=60
threadpool_max_size=0
disable_tcp_switch=yes
type=system

[Main-global]
max_forwards=70
keep_alive_interval=30
contact_expiration_check_interval=30
disable_multi_domain=no
max_initial_qualify_time=0
unidentified_request_period=5
unidentified_request_count=5
unidentified_request_prune_interval=30
type=global
user_agent=asip
debug=no
endpoint_identifier_order=username
default_from_user=asip
default_realm=asip


[1000](Main)
aors=1000
auth=1000-auth
callerid=1000
context=tula
dtmf_mode=rfc4733
moh_suggest=default
type=endpoint
inband_progress=yes
record_on_feature=automixmon
accountcode=2
rtp_keepalive=30
rtp_timeout=1800
rtp_timeout_hold=1800

[1000]
default_expiration=3600
maximum_expiration=7200
max_contacts=100
minimum_expiration=60
remove_existing=no
type=aor
qualify_frequency=0
qualify_timeout=3.0
authenticate_qualify=no

[1000-auth]
type=auth
auth_type=userpass
password=myverysecretpassword
username=1000

#2

try this link
https://wiki.asterisk.org/wiki/display/AST/res_pjsip+Configuration+Examples


#3

Tested with an example from the link above, similarly the same error appears. For the first time I encounter such a mistake (
[Jul 17 08:52:46] WARNING[14024]: db.c:332 ast_db_put: Couldn’t execute statment: SQL logic error or missing database
[Jul 17 08:52:46] ERROR[14024]: res_pjsip_registrar.c:432 register_aor_core: Unable to bind contact ‘sip:6002@my.ip.xxx.xxx:19718;ob’ to AOR '6002’
srv-1*CLI>


#4

Do you have any errors at startup in regards to the database, such as the inability to create it? What does “database show” output? If the local sqlite database can’t be created at startup or becomes corrupted then registrations can’t be saved.


#5

I’m sorry, I do not use the database yet, maybe because of this and there is a second error?
[Jul 17 08:52:46] ERROR [14024]: res_pjsip_registrar.c: 432 register_aor_core: Unable to bind contact ‘sip: 6002@my.ip.xxx.xxx: 19718; ob’ to AOR '6002b
Now I’m going to test dialplan, I’ll unsubscribe.


#6

Asterisk automatically creates a sqlite3 database at startup if it does not exist and uses it to persist information, without you having to do anything. It’s used by registration in PJSIP by default, and by other things. It can also be used from the CLI using the “database” CLI commands and from the dialplan using the DB dialplan function. If this database can’t be created (such as due to permissions) then you’ll see the above.


#7

Many thanks, now I know where to dig …


#8

Remember, you need to recompile the asterisk kernel, the sqlite module was not selected


#9

The sqlite Asterisk module isn’t used for that, that DB functionality is built into the core.


#10

[SOLVED] Thanks solved the problem, it turned out all corny, the classic of the genre, the cases were in the access rights. Thank you all very much again!