I recently set up my asterisk 13 with PJSIP and database. All working fine, but sometimes I get no voice, where most of the time I get a voice. So I need RTP software? following is detail log, I am looking but not found any voice or codec issue, as I set up codec to all, and this is local environment all local services, so there should not be any nat related issue but seem I have configured incorrect nat issue. I migrated and also notice the same issue in old sip servers too and I moved it on new due to this voice issue. So it is sure that it is not software issue, but must be configuration issue. Following is my log. note: I am newbie in PJSIP and it is my first PJSIP installation.
-- Executing [1567241111@default:1] AGI("PJSIP/192.168.56.103-00000004", "myagi.pl,0000FFFF0001,1567241111,,PJSIP/192.168.56.103-00000004,,1547882181.8") in new stack
-- Launched AGI Script /var/lib/asterisk/agi-bin/myagi.pl
<--- Transmitting SIP response (913 bytes) to UDP:192.168.56.103:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 192.168.56.103:5060;received=192.168.56.103;branch=z9hG4bK08e608fd
Call-ID: 25918c527ec2200b25e99b862ff7ac80@192.168.56.103:5060
From: "vendorTest" <sip:0000FFFF0001@192.168.56.103>;tag=as7756e843
To: <sip:1567241111@192.168.56.102>;tag=1bf6a0d2-1c8b-431f-91c7-a074337a7b88
CSeq: 102 INVITE
Server: Asterisk PBX certified/13.21-cert3
Contact: <sip:192.168.56.102:5060>
Allow: OPTIONS, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, UPDATE, PRACK, REGISTER, REFER, MESSAGE
Supported: 100rel, timer, replaces, norefersub
Content-Type: application/sdp
Content-Length: 288
v=0
o=- 2131651698 2131651700 IN IP4 192.168.56.102
s=Asterisk
c=IN IP4 192.168.56.102
t=0 0
m=audio 24874 RTP/AVP 0 8 3 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=maxptime:150
a=sendrecv
<--- Received SIP request (460 bytes) from UDP:192.168.56.103:5060 --->
ACK sip:192.168.56.102:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.56.103:5060;branch=z9hG4bK62ff354e
Max-Forwards: 70
From: "vendorTest" <sip:0000FFFF0001@192.168.56.103>;tag=as7756e843
To: <sip:1567241111@192.168.56.102>;tag=1bf6a0d2-1c8b-431f-91c7-a074337a7b88
Contact: <sip:0000FFFF0001@192.168.56.103:5060>
Call-ID: 25918c527ec2200b25e99b862ff7ac80@192.168.56.103:5060
CSeq: 102 ACK
User-Agent: Asterisk PBX 11.13.1~dfsg-2+deb8u5
Content-Length: 0
My PJSIP configuration calling peer
[192.168.56.103]
type = aor
contact = sip:192.168.56.103
maximum_expiration = 60
minimum_expiration = 60
default_expiration = 180
[192.168.56.103]
type = identify
endpoint = 192.168.56.103
match = 192.168.56.103
[192.168.56.103]
type = endpoint
context = default
dtmf_mode = rfc4733
disallow = all
allow =all
direct_media = yes
language = en
aors = 159.203.27.198
t38_udptl = yes
t38_udptl_ec = none
rtp_symmetric = yes
force_rport = no
rewrite_contact = yes
direct_media = no
My Servers
192.168.56.103 - Asterisk 13 with PJSIP - call receiver
192.168.56.102 - Asterisk 11 with PJSIP - Caller
To make clear I have put voicemail so other part is actualy asterisk replying, normal it asks for password and it does 10 times but 2 times no voice? any idea where I am doing wrong. Should I install RTPengine or RTPProxy. This server will be on internet to provide voip calls and also register sip client,and my client will be public internet user, so they mostly be behind nat!