Activating PJSIP: Difference between revisions

From MiRTA PBX documentation
Jump to navigation Jump to search
No edit summary
No edit summary
Line 31: Line 31:
ps_contacts => odbc,asterisk1,ps_contacts,1
ps_contacts => odbc,asterisk1,ps_contacts,1
ps_contacts => odbc,asterisk2,ps_contacts,2
ps_contacts => odbc,asterisk2,ps_contacts,2
</pre>
Edit sorcery.conf, comment all and add:
<pre>
[res_pjsip]
endpoint=realtime,ps_endpoints
auth=realtime,ps_auths
aor=realtime,ps_aors
domain_alias=realtime,ps_domain_aliases
contact=realtime,ps_contacts
[res_pjsip_endpoint_identifier_ip]
identify=realtime,ps_endpoint_id_ips
</pre>
</pre>

Revision as of 21:58, 23 February 2017

PJSIP is the new SIP stack for asterisk and even it seems not yet "stable" with changes on every new release, it is the only viable choice if you want to use a recent asterisk version. To use it with MiRTA PBX you need to install the latest asterisk version, but before compiling the new version, some activity needs to be performed.

Start by adding the required library

yum -y install pjproject-devel opus-devel gsm-devel

create a new /etc/asterisk/pjsip.conf file and enter the following info:

[transport-udp]
type=transport
protocol=udp
bind=0.0.0.0:5080

edit extconfig.conf and add the pjsip table connections:

ps_endpoints => odbc,asterisk1,ps_endpoints,1
ps_endpoints => odbc,asterisk2,ps_endpoints,2
ps_auths => odbc,asterisk1,ps_auths,1
ps_auths => odbc,asterisk2,ps_auths,2
ps_aors => odbc,asterisk1,ps_aors,1
ps_aors => odbc,asterisk2,ps_aors,2
ps_domain_aliases => odbc,asterisk1,ps_domain_aliases,1
ps_domain_aliases => odbc,asterisk2,ps_domain_aliases,2
ps_endpoint_id_ips => odbc,asterisk1,ps_endpoint_id_ips,1
ps_endpoint_id_ips => odbc,asterisk2,ps_endpoint_id_ips,2
ps_contacts => odbc,asterisk1,ps_contacts,1
ps_contacts => odbc,asterisk2,ps_contacts,2

Edit sorcery.conf, comment all and add:

[res_pjsip]
endpoint=realtime,ps_endpoints
auth=realtime,ps_auths
aor=realtime,ps_aors
domain_alias=realtime,ps_domain_aliases
contact=realtime,ps_contacts

[res_pjsip_endpoint_identifier_ip]
identify=realtime,ps_endpoint_id_ips