Here is the trunk configuration on the freepbx box.
outgoing Trunk name: ToDispatchPBX
host=192.168.62.30
type=friend
quality=yes
incoming User Context: fromDispatchPBX
context=from-internal&from-trunk
type=friend
insecure=very
quality=yes
port=5060
deny=0.0.0.0/0.0.0.0
permit=192.168.62.30/255.255.255.255
disallow=all
allow=ulaw
trustrpid=yes
sendrpid=yes
There is no authentication between the two PBXs - they are both on our internal network, trunk on it’s own VLAN.
I started out with the bare minimum config settings in the trunk, with the same results
Outgoing
host=192.168.62.30
type=friend (I’ve tried, peer, friend, user)
incoming
context=from-internal
type=friend (I’ve tried, peer, friend, user)
Asterisk Log capture from the freepbx while trying to make out external from the Freeswitch PBX, from the Freeswitch it gets sent to the Freepbx box thru the trunk as it is supposed to. but the calling phone gets a ‘not a working number’ error
[2017-08-19 09:51:31] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4153
[2017-08-19 09:51:32] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4153
[2017-08-19 09:51:47] NOTICE[27763] manager.c: 127.0.0.1 tried to authenticate with nonexistent user 'cxpanel'
[2017-08-19 09:51:47] NOTICE[27763] manager.c: 127.0.0.1 failed to authenticate as 'cxpanel'
[2017-08-19 09:51:49] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4106
[2017-08-19 09:51:50] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4106
[2017-08-19 09:51:52] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4154
[2017-08-19 09:51:53] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4154
->>> external call from the FreeSwitch initiated at this time
[2017-08-19 09:51:55] VERBOSE[2589][C-00001505] netsock2.c: Using SIP RTP TOS bits 184
[2017-08-19 09:51:55] VERBOSE[2589][C-00001505] netsock2.c: Using SIP RTP CoS mark 5
[2017-08-19 09:51:55] VERBOSE[27768][C-00001505] pbx.c: Executing [**externalphonenumber**@from-trunk-sip-ToDispatchPBX:1] Set("SIP/ToDispatchPBX-000030f3", "GROUP()=OUT_12") in new stack
[2017-08-19 09:51:55] VERBOSE[27768][C-00001505] pbx.c: Executing [**externalphonenumber**@from-trunk-sip-ToDispatchPBX:2] Goto("SIP/ToDispatchPBX-000030f3", "from-trunk,**externalphonenumber**,1") in new stack
[2017-08-19 09:51:55] VERBOSE[27768][C-00001505] pbx_builtins.c: Goto (from-trunk,**externalphonenumber**,1)
[2017-08-19 09:51:55] VERBOSE[27768][C-00001505] pbx.c: Executing [**externalphonenumber**@from-trunk:1] Set("SIP/ToDispatchPBX-000030f3", "__FROM_DID=**externalphonenumber**") in new stack
[2017-08-19 09:51:55] VERBOSE[27768][C-00001505] pbx.c: Executing [**externalphonenumber**@from-trunk:2] NoOp("SIP/ToDispatchPBX-000030f3", "Received an unknown call with DID set to **externalphonenumber**") in new stack
[2017-08-19 09:51:55] VERBOSE[27768][C-00001505] pbx.c: Executing [**externalphonenumber**@from-trunk:3] Goto("SIP/ToDispatchPBX-000030f3", "s,a2") in new stack
[2017-08-19 09:51:55] VERBOSE[27768][C-00001505] pbx_builtins.c: Goto (from-trunk,s,2)
[2017-08-19 09:51:55] VERBOSE[27768][C-00001505] pbx.c: Executing [s@from-trunk:2] Answer("SIP/ToDispatchPBX-000030f3", "") in new stack
[2017-08-19 09:51:56] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4152
[2017-08-19 09:51:56] VERBOSE[27768][C-00001505] pbx.c: Executing [s@from-trunk:3] Log("SIP/ToDispatchPBX-000030f3", "WARNING,Friendly Scanner from 192.168.62.30;rport;branch=z9hG4bKF4eZQFeS5HrBD") in new stack
[2017-08-19 09:51:56] WARNING[27768][C-00001505] Ext. s: Friendly Scanner from 192.168.62.30;rport;branch=z9hG4bKF4eZQFeS5HrBD
[2017-08-19 09:51:56] VERBOSE[27768][C-00001505] pbx.c: Executing [s@from-trunk:4] Wait("SIP/ToDispatchPBX-000030f3", "2") in new stack
[2017-08-19 09:51:56] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4109
[2017-08-19 09:51:57] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4152
[2017-08-19 09:51:57] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4109
[2017-08-19 09:51:58] VERBOSE[27768][C-00001505] pbx.c: Executing [s@from-trunk:5] Playback("SIP/ToDispatchPBX-000030f3", "ss-noservice") in new stack
[2017-08-19 09:51:58] VERBOSE[27768][C-00001505] file.c: <SIP/ToDispatchPBX-000030f3> Playing 'ss-noservice.ulaw' (language 'en')
[2017-08-19 09:51:58] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4192
[2017-08-19 09:51:59] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4192
[2017-08-19 09:51:59] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4151
[2017-08-19 09:52:00] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4151
[2017-08-19 09:52:02] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4153
[2017-08-19 09:52:03] VERBOSE[27768][C-00001505] pbx.c: Executing [s@from-trunk:6] SayAlpha("SIP/ToDispatchPBX-000030f3", "**externalphonenumber**") in new stack
[2017-08-19 09:52:03] VERBOSE[27768][C-00001505] file.c: <SIP/ToDispatchPBX-000030f3> Playing 'digits/9.ulaw' (language 'en')
[2017-08-19 09:52:03] NOTICE[27836] manager.c: 127.0.0.1 tried to authenticate with nonexistent user 'cxpanel'
[2017-08-19 09:52:03] NOTICE[27836] manager.c: 127.0.0.1 failed to authenticate as 'cxpanel'
[2017-08-19 09:52:03] VERBOSE[27768][C-00001505] file.c: <SIP/ToDispatchPBX-000030f3> Playing 'digits/7.ulaw' (language 'en')
[2017-08-19 09:52:04] NOTICE[2589] chan_sip.c: Received SIP subscribe for peer without mailbox: 4153
[2017-08-19 09:52:04] VERBOSE[27768][C-00001505] file.c: <SIP/ToDispatchPBX-000030f3> Playing 'digits/0.ulaw' (language 'en')
^X[2017-08-19 09:52:05] VERBOSE[27768][C-00001505] file.c: <SIP/ToDispatchPBX-000030f3> Playing 'digits/5.ulaw' (language 'en')
[2017-08-19 09:52:06] VERBOSE[27768][C-00001505] file.c: <SIP/ToDispatchPBX-000030f3> Playing 'digits/8.ulaw' (language 'en')
[2017-08-19 09:52:06] VERBOSE[27768][C-00001505] file.c: <SIP/ToDispatchPBX-000030f3> Playing 'digits/1.ulaw' (language 'en')
^C