Newbie here… I did a new install of FreePBX 16 and configured Mynetfone as a pjsip trunk. In/out calls on this trunk work fine, however unable to forward to a mobile number. The incoming call I need forwarded come in on a different pjsip trunk (Internode) which again works fine for all purposes. I tried using both Misc and Custom Destinations to no avail. I can call the forwarded external mobile number from extensions using Mynefone trunk OK.
FYI. I did try Mynetfone as a chan_sip trunk and forwarding seem to work, but that’s obsolete and not supported, so really need the setup working on chan_pjsip. The actual pjsip setup I have is from info on simtex website (too green to insert link)
Similar issue was reported in but nothing mentioned to help resolve:
“Pjsip setup for MyNetFone”
You have a very short no answer timeout of 8 seconds, which won’t be related to the use of chan_pjsip. Are you sure that the called party actually answered within 8 seconds, as this looks like a straightforward no answer case.
Thanks for the reply and well spotted, but “no cigar”.
Dropped the ring group timeout down on purpose because was sick of waiting 20sec while testing, but makes no difference here… and BTW, exact same timeout works when switch same VSP to chan_sip, with behaviour as expected - ring-group (for 8 sec) then fw and ring nominated mobile.
Gut feel is on possible pjsip limitation/compatibility on the VSP side, but hopeful there is something else obvious in the call trace logs that might be able to address.
In that case, the easiest way to get a clue as to what is wrong is for you to issue “pjsip set logger on” to the Asterisk CLI, to get a protocol trace in the full log file.
I don’t think you’re looking in the right place. What I see is:
Call comes on Internode trunk, ring-group rings for 8sec and times out:
Line 565. [2022-03-15 21:56:32] – Nobody picked up in 8000 ms
Then about line 779 start seeing entries on Mynetfone trunk call’s suppose to be forwarded on. There is an error in line 789 not sure is related. Lots of attempts then to dial forward on Mynetfone trunk…
And further on:
This is where is falling a part I think!
Line 930. [2022-03-15 21:56:32] <--- Received SIP response (372 bytes) from UDP:125.213.160.81:5060 --->**
Line 931. [2022-03-15 21:56:32] SIP/2.0 502 Bad Gateway**
Line 932. [2022-03-15 21:56:32] Via: SIP/2.0/UDP 203.122.212.22:5160;rport;branch=z9hG4bKPj686b19e4-321d-49ba-8668-f6caa23a9793**
…
Line 963. [2022-03-15 21:56:32] == Everyone is busy/congested at this time (1:0/0/1)
Line 964. [2022-03-15 21:56:32] -- Executing [s@macro-dialout-trunk:35] NoOp("PJSIP/Internode_0883645466-00000069", "Dial failed for some reason with DIALSTATUS = CHANUNAVAIL and HANGUPCAUSE = 27") in new stack
…
Line 969. 2022-03-15 21:56:32] -- <PJSIP/Internode_0883645466-00000069> Playing 'all-circuits-busy-now.alaw' (language 'en_AU')
What is puzzling though is that dialling the forwarded number, over the Mynetfone trunk from any extensions works fine!?..
It is not the issue, just purely coincidental, but confusing nonetheless, so I’ll explain.
Because of limited resources for testing, the call forward number on timeout is set to the very mobile, I’m calling from. This works fine when trunk is chan_sip, calling, ringroup for 8 sec, timeout, call forwarded to same mobile I’m calling from, but because I’m on call already goes straight to my cell voicemail, so I hear the voicemail greeting.
When configuring same VSP trunk to pjsip, after ring-group times out, I hear the congestion msg - all circuits are busy. All this reflected in the logs you were looking at.
Unfortunately I need to go live with this system tomorrow for my customer, so will downgrade and stick with chan_sip, but will still be in a position to investigate further after hours and weekends.
Please let me know if anything else is worth trying to attempt to resolve. Thx.
You could provide a SIP trace from chan_sip so it can be compared. From purely an Asterisk SIP signaling perspective the callerid thing is the only thing that sticks out without a working case to compare against.
It has been a while (the system is now production) and I cannot seem to justify spending more time investigating/fixing pjsip for this VSP (Mynetfone). Would rather switch providers later, once I get a chance to evaluate and test a decent one supporting pjsip.
Summarising what worked for me, in case others stumble across this:
extensions and Internode trunk use pjsip
Mynetfone trunk uses chan_sip (call forward on this trunk does not work when configured as pjsip)