M
M
maniac_by2019-05-22 14:17:34
linux
maniac_by, 2019-05-22 14:17:34

How to properly integrate 3CX with Asterisk?

Hello. There are several questions regarding the connection of 3CX with Asterisk.
Firstly, do I understand correctly that the trunk passes through 1 number?
Second, does the user (and trunk) number need to be registered on both 3CX and Asterisk?
I managed to somehow set up a connection between Asterisk and 3CX. From 3CXa it dials to the IP phone (Asterisk registration), but from the IP phone to 3CXa it is not possible to reach (busy)
IP Phone (Asterisk) -> 3CX

== Using SIP RTP CoS mark 5
    -- Executing [[email protected]:1] Dial("SIP/2830-0000d558", "SIP/test3cx-outgoing/}") in new stack
  == Using SIP RTP CoS mark 5
    -- Called SIP/test3cx-outgoing/}
  == Everyone is busy/congested at this time (1:0/0/1)
    -- Executing [[email protected]:2] Congestion("SIP/2830-0000d558", "1") in new stack
  == Spawn extension (office, 2835, 2) exited non-zero on 'SIP/2830-0000d558'
    -- Executing [[email protected]:1] Congestion("SIP/2830-0000d558", "1") in new stack
  == Spawn extension (office, h, 1) exited non-zero on 'SIP/2830-0000d558'

3CX -> IP Phone (Asterisk)
Using SIP RTP CoS mark 5
    -- Executing [[email protected]:1] Dial("SIP/2901-0000d556", "SIP/2830") in new stack
  == Using SIP RTP CoS mark 5
    -- Called SIP/2830
    -- SIP/2830-0000d557 is ringing

Configs:
Asterisk:
sip.conf
register => 2901:[email protected]:5060/2901

[test3cx-outgoing]
host=ip
port=5060
username=2901
fromuser=2901
secret=passwd
sendrpid=yes
qualify=yes
type=friend

[test3cx-incoming]
host=ip
port=5060
type=friend
trustpid=yes
context=office

extensions.conf
TEST3CX = SIP/test3cx-outgoing/
TEST3CX2 = SIP/test3cx-incoming/

;test3cx
exten => 2835,1,Dial(${TEST3CX})
;test3cx

2901 - number registered on Asterisk for Trunk
2835 - number on both 3cx and Asterisk.
3CX 5ce53038802aa105844833.png
What's wrong?
And another bonus question. We use a script system on Asterisk, which resolves access via trunks and a self-written console to all this (including registration of numbers). It turns out that if only 1 number can be used for a trunk from 3cxa, then all permissions will have to be issued on nageo ??

Answer the question

In order to leave comments, you need to log in

[[+comments_count]] answer(s)
M
maniac_by, 2019-05-22
@maniac_by

Yes, I'm a fool.
;test3cx
exten => 2835,1,Dial(${TEST3CX}${EXTEN})
;test3cx
But the first two questions are still valid

A
Aleksandr Tumanov, 2019-06-05
@tuman007

Firstly, do I understand correctly that the trunk passes through 1 number?
Second, does the user (and trunk) number need to be registered on both 3CX and Asterisk?
1. I did not understand the question.
2. You can set up a trunk with Aster without registering with 3CX. The extension number must be registered, otherwise you will not be able to receive a call, unless, of course, forwarding is enabled.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question