[SOLVED] DPMA with PJSIP

Hi,

I prepare the migration of my servers Asterisk 11 with SIP to servers Asterisk 13 with PJSIP.
I use DIGIUM phones with the module res_digium_phone.

With Asterisk 11 + SIP + DPMA, my phones connect to the SIP account of the main server and alternate server simultaneously. It’s the Digium session that switches from one server to another.

With Asterisk 13 + PJSIP + DPMA, my phones connect to the SIP account only on the main server. When the main server is off, my phones lose connection to the server and do not switch to the alternate server.

The configuration of the res_digium_phone.conf file is identical on both server types (Asterisk 11 and Asterisk 13) :

[general]
;-----------------------------------------------------------------------------
; GENERAL
;-----------------------------------------------------------------------------
; -- Authentification Options
server_uuid=astsip5.mdc
userlist_auth=disabled
config_auth=pin
; -- mDNS Discovery disable
service_discovery_enabled=no
; -- File Directory pour Display Rules
file_directory=/var/lib/asterisk/digium_phones

;-----------------------------------------------------------------------------
; NETWORK
;-----------------------------------------------------------------------------
[network-global](!)
type=network
cidr=172.25.0.0/16
registration_port=5060
alternate_registration_port=5060
; File URL pour : applications, blfitems, logos, ringtones, firmwares
file_url_prefix=http://voip.mydomain.com/phones/digium
ntp_server=172.20.170.12
udp_ka_interval=60

[astsip1.mdc_astsip1.pa6](network-global)
alias=astsip1.mdc_astsip1.pa6
registration_address=172.20.170.31
alternate_registration_address=172.20.171.31

[...]

[astsip5.mdc_astsip5.pa6](network-global)
alias=astsip5.mdc_astsip5.pa6
registration_address=172.20.170.35
alternate_registration_address=172.20.171.35

;-----------------------------------------------------------------------------
; FIRMWARE
;-----------------------------------------------------------------------------
[D40-2_4_1]
type=firmware
model=D40
version=2_4_1
file=firmware/firmware_2_4_1_package/2_4_1_D40_firmware.eff

[...]

;-----------------------------------------------------------------------------
; PHONE & LINE
;-----------------------------------------------------------------------------
;- Phone : GLOBAL ------------------------
[phone-global]
type=phone
firmware=D40-2_4_1
firmware=D60-2_4_1
firmware=D65-2_4_1
firmware=D70-2_4_1
pin=voicemail
timezone=Europe/Paris
active_locale=fr_FR
ntp_resync=86400
ringtone=old_ringtone
ringtone=dual_ringtone
active_ringtone=dual_ringtone
; Logos : into file_url_prefix
d40_logo_file=logos/D40.png
d60_logo_file=logos/D60.png
d65_logo_file=logos/D65.png
d70_logo_file=logos/D70.png
blf_unused_linekeys=yes
contacts_max_subscriptions=20
application=annuaire
application=voicemail
enable_check_sync=yes
web_ui_enabled=yes
codecs=PCMU,PCMA,G722,G729,iLBC,!G7221,!L16,!L16-256,!G726-32,!opus
show_call_parking=no
8021x_passthrough=yes
8021x_eapol_on_disconnect=yes
;- Line : GLOBAL -------------------------
[line-global]
type=line
digit_map=[0-9]xxx|1[578]|19[16]|11[02459]|116000|9xxxx|0[1-9]xxxxxxxx
transport=udp

;-----------------------------------------

;- Phone : 0123456789 --------------------
[P0123456789](phone-global)
network=astsip5.mdc_astsip5.pa6
full_name=P0123456789
line=0123456789
; Contacts : into file_directory
contact=contacts/0123456789_contacts.xml
; BLF conf : into file_url_prefix
blf_contact_group=ADOMA
blf_items=blfitems/0123456789_blfitems.xml
;- Line : 0123456789 ---------------------
[0123456789](line-global)
line_label=0123456789
;-----------------------------------------

And pjsip.conf :

;-- . globals configuration -----------------;
[transport-udp]
type=transport
protocol=udp
bind=0.0.0.0

[global]
type=global
default_outbound_endpoint=dpma_endpoint

[dpma_endpoint]
type=endpoint
;--------------------------------------------;

;-- . templates sip accounts ----------------;
[endpoint-sip](!)
type=endpoint
dtmf_mode=rfc4733
direct_media=no
trust_id_inbound=yes
send_rpid=yes
send_pai=yes
language=fr
allow_subscribe=yes
;allow_overlap=no
device_state_busy_at=1

[endpoint-sfp](!,endpoint-sip)

[codecs-ulaw](!)
allow=!all,ulaw,alaw,g722

[codecs-g729](!)
allow=!all,g729,ulaw,alaw,g722

;[codecs-opusXX](!)
;allow=!all,opusXX,ulaw,alaw,g722

[aor-sip](!)
type=aor
max_contacts=1
;remove_existing=yes
qualify_frequency=10
;--------------------------------------------;

;-- . 0123456789 ----------------------------;
[0123456789](endpoint-sip,codecs-ulaw)
aors=0123456789
auth=0123456789
mailboxes=0123456789@default
context=i0123456789
callerid="TEST NEW AST 13.0" <0123456789>

[0123456789](aor-sip)

[0123456789]
type=auth
username=0123456789
password=1234
;--------------------------------------------;

Thanks in advance for your help :smile:

A private message has been sent…

Query solved; per reporter, a firewall was blocking ports on the backup server.

1 Like