# Web GUI : Adding trunks with inbound and outbound routes

**URL:** <https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125>\
**Category:** Installation/Configuration\
**Created:** [January 3, 2020, 12:09am UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125 "2020-01-03T00:09:47Z")\
**Posts on this page:** 15\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ramblin](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/ramblin/32/34_2.png) [@Ramblin](https://wazo-platform.discourse.group/u/Ramblin)\
**Post date:** [January 3, 2020, 12:09am UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/1 "2020-01-03T00:09:47Z")

</div>

Can someone give me some guidance on what steps to take - using the Web GUI - to have inbound and outbound routes properly configured with trunk(s) ?

I am doing everything via the Web GUI for Wazo and I have installed Wazo with two Aastra IP phones configured and working. I can call one phone from the other and vice versa.

I also added a trunk to my service provider and when I run the CLI command

> asterisk -rx “pjsip show registrations”

it shows the trunk as registered.

However, I have configured an Incall route and and Outcall route using the Wazo Web GUI and neither are working. When I call the Inbound numnber, it says “The number has not been assigned.” Since i just moved the trunk over from a working PBX, I know the number is working at the provider end.

I did restart the server in case something needed a refresh to work, but no difference.

Is there some guidance somewhere on making Incalls and Outcalls work via the Wazo Web GUI?

… Hopefull …

---

<div class="post-metadata">

**Author:** ![Ramblin](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/ramblin/32/34_2.png) [@Ramblin](https://wazo-platform.discourse.group/u/Ramblin)\
**Post date:** [January 3, 2020, 6:25pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/2 "2020-01-03T18:25:06Z")

</div>

@sduthil

I had kind of hijacked @Disciplus topic at  
[https://wazo-platform.discourse.group/t/wazo-ui-connexion-impossible/121](https://wazo-platform.discourse.group/t/wazo-ui-connexion-impossible/121)  
on root user/password so I decided to continue our conversation here in this topic dedicated to our conversation.

I activated

> asterisk -r

to start monitoring the log of activity when making the call tests

I have the incalls getting to my server but am getting the errror messages as shown (I replaced the at symbol with {at} since the forum thought I was trying to tag people with each use of the at symbol and would not let me post)

For Outcall from extension 11002 to {RealNumberHidden}

> > [2020-01-03 12:53:06.3136] NOTICE[11564]: res\_pjsip\_session.c:3057 new\_invite: Call from ‘11002’ (UDP:{RealISourcePaddressHidden}:57956) to extension ‘{RealNumberHidden}’ rejected because extension not found in context ‘StokeInternalContext’.

The {RealNumberHidden} is the 10-digit NorthAmerican number bing dialed, which, since the Internal Context only is defined to allow extensions from numbers ranging from 10000 to 99999 , it is understandable that it would not contain the {RealNumberHidden}. In the Incall Context, I defined the allowed numbers to be 10-digit from 2010000000 to 9999999999.

For Incall to user SoftPhone from {RealNumberHidden}

> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:1] NoOp(“PJSIP/{RealNumberHidden}-0000000f”, “”) in new stack  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:2] GotoIf(“PJSIP/{RealNumberHidden}-0000000f”, “1?:not-pjsip”) in new stack  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:3] GotoIf(“PJSIP/{RealNumberHidden}-0000000f”, “1?:error-loop”) in new stack  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:4] Set(“PJSIP/{RealNumberHidden}-0000000f”, “XIVO\_DID\_NEXT\_EXTEN=s”) in new stack  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:5] Set(“PJSIP/{RealNumberHidden}-0000000f”, “XIVO\_FROM\_S=1”) in new stack  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:6] Goto(“PJSIP/{RealNumberHidden}-0000000f”, “StokeIncallContext,s,1”) in new stack  
> [Jan 3 13:09:07] – Goto (StokeIncallContext,s,1)  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:1] NoOp(“PJSIP/{RealNumberHidden}-0000000f”, “”) in new stack  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:2] GotoIf(“PJSIP/{RealNumberHidden}-0000000f”, “1?:not-pjsip”) in new stack  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:3] GotoIf(“PJSIP/{RealNumberHidden}-0000000f”, “0?:error-loop”) in new stack  
> [Jan 3 13:09:07] – Goto (StokeIncallContext,s,10)  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:10] NoOp(“PJSIP/{RealNumberHidden}-0000000f”, “”) in new stack  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:11] Log(“PJSIP/{RealNumberHidden}-0000000f”, “ERROR, Dialplan loop detected. Got PJSIP header To: sip:s@192.168.1.201”) in new stack  
> [2020-01-03 13:09:07.0920] ERROR[12564][C-0000000d]: Ext. s:11 {at} StokeIncallContext: Dialplan loop detected. Got PJSIP header To: sip:s{at}{RealServerIPaddressHidden}  
> [Jan 3 13:09:07] – Executing [s{at}StokeIncallContext:12] Hangup(“PJSIP/{RealNumberHidden}-0000000f”, “”) in new stack  
> [Jan 3 13:09:07] == Spawn extension (StokeIncallContext, s, 12) exited non-zero on ‘PJSIP/{RealNumberHidden}-0000000f’

which looks like it is looping, but I do not speak Asterisk as well as you I am sure.

I did notice that there is a spot when defining Contexts to include other Contexts, but I did not have that setup when I ran these tests. I did try adding the to-extern and from-extern Contexts to the Internal Context and other combinations but it did not seem to make a difference.

Is this giving you any indication why the Incalls and Outcalls are not working?

Just to show that the trunk is registered, when I did a

> asterisk -rx “pjsip show registrations”

I got back

> # \<Registration/ServerURI…\> \<Auth…\> \<Status…\>
> 
> reg\_{RealNumberHidden}{at}{HostFQDNhidden}/sip:{HostFQDN-lessTLD-hidden}. auth\_reg\_{RealNumberHidden}{at}sip02.unlimitel.ca Registered

Not sure where to go next …

Any suggestions are appreciated.

---

<div class="post-metadata">

**Author:** ![sduthil](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@sduthil](https://wazo-platform.discourse.group/u/sduthil)\
**Post date:** [January 3, 2020, 9:01pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/3 "2020-01-03T21:01:06Z")

</div>

Hi Ramblin,

thanks for creating the dedicated topic.

To paste logs, you can use the Preformatted text option, or the Code block (triple backquote), as defined in the markdown syntax, like this:

````auto
```
I c@n write @s m@ny @ th@t I w@nt
```

````

About your outgoing calls: you need to include the context to-extern inside StokeInternalContext. You seem to have done this already, but make sure it this way and not the other way around. You should not include from-extern inside StokeInternalContext.

To ensure you can place an outgoing call, use the command `asterisk -rx "dialplan show realnumber@StokeInternalContext"`. You should see something like this:

```auto
[Included context 'to-extern' created by 'pbx_config']                                                  
  '_97.' => 1. Set(XIVO_BASE_CONTEXT=${CONTEXT}) [exec.1578081957365167.-1339782336:1631]
                    2. Set(XIVO_BASE_EXTEN=${EXTEN}) [exec.1578081957365167.-1339782336:1632]
                    3. GoSub(outcall,s,1(39,)) [exec.1578081957365167.-1339782336:1633]
  '_9X.' => 1. Set(XIVO_BASE_CONTEXT=${CONTEXT}) [exec.1578081957365167.-1339782336:1643]
                    2. Set(XIVO_BASE_EXTEN=${EXTEN}) [exec.1578081957365167.-1339782336:1644]
                    3. GoSub(outcall,s,1(2,)) [exec.1578081957365167.-1339782336:1645]
                                                                                                          
-= 2 extensions (6 priorities) in 1 context. =-                                                           

```

The outcall “regexp” goes in the Outcall form, in the tab Exten, in the field “Extension”. And you are absolutely right about adding `_` before the call routing “regexp” in the Outcall form: they must be there. If they’re not, you will see them missing from the `dialplan show` output.

Now, about your incalls: make sure your trunk is configured with Context = from-extern. I’d like to see the start of the loop: you showed us the end of the loop, but I’d like to know how it started, in order to find the real source of the loop 🙂 I guess it is a side-effect of your context inclusion of from-extern inside internal, which you should remove.

---

<div class="post-metadata">

**Author:** ![Ramblin](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/ramblin/32/34_2.png) [@Ramblin](https://wazo-platform.discourse.group/u/Ramblin)\
**Post date:** [January 4, 2020, 7:59pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/4 "2020-01-04T19:59:47Z")

</div>

Well,

I thought I was going to attach a couple of files to show both my setup/configuration and the results of the asterisk queries, but the system will not let me upload .txt files so this will be a LONG reply, but I wanted you to know what has been setup so hopfully it is worth it.

A couple of questions first:

- Do I need to port forward or open firewall ports?  
I thought not since outcalls reach out and incalls are based on ongoing registration that originated from inside the LAN but ???  
It does look like incalls are getting to server  
Don’t know whow to tell if outcalls are getting out
- Are the correct “Host” settings  
– Dynamic for Lines  
– Static (pointing to server) for trunks  
This is what I have used (arrived at via trial and error) and it seems to be working, but wanted to check.

FYI, I have left actual data in here. I kow this means changing the setup after I get it working, but wanted to show you exactly what I am seeing so here it is.

To first answer your specific questions re included Contexts and Dialplans:

- My previous setup used to send you information did not have any Contexts included in any other Contexts. For this setup, following your instructions, I included to-extern (Outcall) Context in the Internal context and no other included Contexts in any other Context.
- The results of ’ asterisk -rx “dialplan show realnumber@StokeInternalContext” ’ were different, based on the number being dialed, which is at is should have been since I setup a very tight routing (\_519XXXXXXX) for a number to area code 519 and a very open routing (\_X.) for calls to any other area code (North American). So the dialplan when calling 5195749401 was two-stage (rollover to second route after first route failed) but the dialplan when calling 4162262143 was single stage, as they both should have been. The actual outputs were:

> dialplan show 5195749401@StokeInternalContext  
> [Included context ‘StokeOutcallContext’ created by ‘pbx\_config’]  
> ‘\_519XXXXXXX’ =\> 1. Set(XIVO\_BASE\_CONTEXT=${CONTEXT}) [exec.1578160382615053.140137411409664:75]  
> 2. Set(XIVO\_BASE\_EXTEN=${EXTEN}) [exec.1578160382615053.140137411409664:76]  
> 3. GoSub(outcall,s,1(2,)) [exec.1578160382615053.140137411409664:77]  
> ‘\_X.’ =\> 1. Set(XIVO\_BASE\_CONTEXT=${CONTEXT}) [exec.1578160382615053.140137411409664:79]  
> 2. Set(XIVO\_BASE\_EXTEN=${EXTEN}) [exec.1578160382615053.140137411409664:80]  
> 3. GoSub(outcall,s,1(3,)) [exec.1578160382615053.140137411409664:81]
> 
> -= 2 extensions (6 priorities) in 1 context. =-

> dialplan show 4162262143@StokeInternalContext  
> [Included context ‘StokeOutcallContext’ created by ‘pbx\_config’]  
> ‘\_X.’ =\> 1. Set(XIVO\_BASE\_CONTEXT=${CONTEXT}) [exec.1578160382615053.140137411409664:79]  
> 2. Set(XIVO\_BASE\_EXTEN=${EXTEN}) [exec.1578160382615053.140137411409664:80]  
> 3. GoSub(outcall,s,1(3,)) [exec.1578160382615053.140137411409664:81]
> 
> -= 1 extension (3 priorities) in 1 context. =-

However, neither call resulted in in a call getting to the number. A more detailed asterisk log result is shown below.

Just to show you that the trunks are registering, the output of ’ asterisk -rx “pjsip show registrations” ’ showed both trunks registered

> pjsip show registrations
> 
> # \<Registration/ServerURI…\> \<Auth…\> \<Status…\>
> 
> reg\_4162269542@sip02.unlimitel.ca/sip:sip02.unlimitel. auth\_reg\_4162269542@sip02.unlimitel.ca Registered  
> reg\_5198803610@sip06.unlimitel.ca/sip:sip06.unlimitel. auth\_reg\_5198803610@sip06.unlimitel.ca Registered
> 
> Objects found: 2

and the outlput of ’ asteris -rx “pjsip show contacts” ’ showed all Contacts working

> pjsip show contacts
> 
> # Contact: \<Aor/ContactUri…\> \<Hash…\> \<RTT(ms)…\>
> 
> Contact: 11002/sip:11002@192.168.1.149:51071;rinstance= 3c508ac860 Avail 107.378  
> Contact: 4162269542/sip:4162269542@192.168.1.201:5060 decfb63d0d Avail 0.439  
> Contact: 5198803610/sip:5198803610@192.168.1.201:5060 6896e5edf6 Avail 0.897  
> Contact: mcoffice-home/sip:mcoffice-home@192.168.1.153: 40c100a50d Avail 29.426  
> Contact: mcoffice\_ayuda/sip:mcoffice\_ayuda@192.168.1.15 4bcbb4e4bd Avail 32.791  
> Contact: rcoffice\_ayuda/sip:rcoffice\_ayuda@192.168.1.19 26c3534de7 Avail 29.337  
> Contact: rcoffice\_home/sip:rcoffice\_home@192.168.1.192: 23405089e5 Avail 30.200
> 
> Objects found: 7

and the output of ’ asterisk -rx “pjsip show endpoints” ’ showed the endpoints all available, excpet one endpoint that was not created by me (at least not intentionally …)

> pjsip show endpoints
> 
> # Endpoint: \<Endpoint/CID…\> \<State…\> \<Channels.\> I/OAuth: \<AuthId/UserName…\> Aor: \<Aor…\> Contact: \<Aor/ContactUri…\> \<Hash…\> \<RTT(ms)…\> Transport: \<TransportId…\> \<BindAddress…\> Identify: \<Identify/Endpoint…\> Match: \<criteria…\> Channel: \<ChannelId…\> \<State…\> \<Time…\> Exten: \<DialedExten…\> CLCID: \<ConnectedLineCID…\>
> 
> Endpoint: 11002/5195551212 Not in use 0 of inf  
> InAuth: 11002/11002  
> Aor: 11002 1  
> Contact: 11002/sip:11002@192.168.1.149:51071;rinsta 3c508ac860 Avail 107.378  
> Transport: transport-udp udp 0 0 0.0.0.0:5060
> 
> Endpoint: 4162269542 Not in use 0 of inf  
> OutAuth: 4162269542/4162269542  
> Aor: 4162269542 0  
> Contact: 4162269542/sip:4162269542@192.168.1.201:50 decfb63d0d Avail 0.482  
> Transport: transport-udp udp 0 0 0.0.0.0:5060  
> Identify: 4162269542/4162269542  
> Match: 192.168.1.201/32
> 
> Endpoint: 5198803610 Not in use 0 of inf  
> OutAuth: 5198803610/5198803610  
> InAuth: 5198803610/5198803610  
> Aor: 5198803610 0  
> Contact: 5198803610/sip:5198803610@192.168.1.201:50 6896e5edf6 Avail 0.897  
> Transport: transport-udp udp 0 0 0.0.0.0:5060  
> Identify: 5198803610/5198803610  
> Match: 192.168.1.201/32
> 
> Endpoint: apn23RVVX8 Unavailable 0 of inf  
> InAuth: apn23RVVX8-auth/apn23RVVX8  
> Aor: apn23RVVX8 100  
> Transport: transport-udp udp 0 0 0.0.0.0:5060
> 
> Endpoint: mcoffice-home/5195710413 Not in use 0 of inf  
> InAuth: mcoffice-home/mcoffice-home  
> Aor: mcoffice-home 1  
> Contact: mcoffice-home/sip:mcoffice-home@192.168.1. 40c100a50d Avail 30.010  
> Transport: transport-udp udp 0 0 0.0.0.0:5060
> 
> Endpoint: mcoffice\_ayuda/5199572414 Not in use 0 of inf  
> InAuth: mcoffice\_ayuda/mcoffice\_ayuda  
> Aor: mcoffice\_ayuda 1  
> Contact: mcoffice\_ayuda/sip:mcoffice\_ayuda@192.168. 4bcbb4e4bd Avail 31.914  
> Transport: transport-udp udp 0 0 0.0.0.0:5060
> 
> Endpoint: rcoffice\_ayuda/5199572414 Not in use 0 of inf  
> InAuth: rcoffice\_ayuda/rcoffice\_ayuda  
> Aor: rcoffice\_ayuda 1  
> Contact: rcoffice\_ayuda/sip:rcoffice\_ayuda@192.168. 26c3534de7 Avail 29.307  
> Transport: transport-udp udp 0 0 0.0.0.0:5060
> 
> Endpoint: rcoffice\_home/5195710413 Not in use 0 of inf  
> InAuth: rcoffice\_home/rcoffice\_home  
> Aor: rcoffice\_home 1  
> Contact: rcoffice\_home/sip:rcoffice\_home@192.168.1. 23405089e5 Avail 30.342  
> Transport: transport-udp udp 0 0 0.0.0.0:5060
> 
> Objects found: 8

so, this is where I currently sit:

- I have 2 devices and one softphone setup and working perfectly as long as I stay inside my LAN. They can call back and forth to each other.
- I have two trunks that are connected to a provider and registered.
- I have two Incall routes setup and two Outcall routes setup but I cannot receive calls or call out, event though the inbound calls are getting to the server and the outbound calls do appear to be caught properly by the established routes (Extensions).

Now here comes the lengthy part (as if the above was short) ☹ (sorry)

=========================================================

My setup

> Setup - everything SIP
> 
> Set Sequence (shown differently below to help clarity):  
> Provisioning  
> Devices  
> Users  
> Lines  
> Trunks  
> Incalls  
> Outcalls
> 
> System setup  
> (More to come once I get it working)  
> Room 1 - RC Office with Device 1 having 2 lines: 1 for home and 1 for business  
> Room 2 - MC Office with Device 2 having 2 lines: 1 for home and 1 for business  
> PC - Soft Phone with no Device and 1 line for whatever is needed
> 
> Contexts
> 
> Context StokeInternal = Internal  
> Included Context = to-extern  
> Range: 10000 to 99999
> 
> Context StokeIncall = from-extern  
> Included Context = none  
> Range: 2010000000 to 9999999999
> 
> Context StokeOutcall = to-extern  
> Included Context = none
> 
> Trunks  
> All trunks with Host = {server IP Address = 192.168.1.201}
> 
> Trunk 1  
> Context = from-extern  
> Host = Static =\> {server IP Address = 192.168.1.201}  
> Number associated = 5198803610  
> Options = as assigned by default by Wazo
> 
> Trunk 2  
> Context = from-extern  
> Host = Static =\> {server IP Address = 192.168.1.201}  
> Number associated = 4162269542  
> Options = As defined by default with Wazo plus custom for provider
> 
> Lines  
> (All Lines with Host = Dynamic)
> 
> Line 1  
> Softphone
> 
> Line 2 - rcoffice-home  
> Device A - Line 1
> 
> Line # - rcoffice-ayuda  
> Device A - Line 2
> 
> Line 4 - mcoffice-home  
> Device B - Line 1
> 
> Line 5 - mcoffice-ayuda  
> Device B - Line 2
> 
> Devices
> 
> Device 1  
> Aastra  
> Line 1 = rcoffice-home  
> Line 3 = rcoffice-ayuda
> 
> Device 2  
> Aastra  
> Line 1 = mcoffice-home  
> Line 3 - mcoffice-ayuda
> 
> Users
> 
> User 1 - Softphone
> 
> User 2 - StokeHome  
> Device A Line 1  
> Device B - Line 1
> 
> User 3 - StokeAyuda  
> Device A - Line 2  
> Device B - Line 2
> 
> Incalls
> 
> 5198803610 → User StokeHome = Lines 2 and 4  
> 4162269542 → User SoftPhone = Line 1
> 
> Outcalls
> 
> \_519XXXXXXX for Trunk 1  
> \_X. for Trunk 2

=========================================================

Outputs from asterisk queries - added in seperate replay (character count exceeded for one reply)

---

<div class="post-metadata">

**Author:** ![Ramblin](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/ramblin/32/34_2.png) [@Ramblin](https://wazo-platform.discourse.group/u/Ramblin)\
**Post date:** [January 4, 2020, 8:01pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/5 "2020-01-04T20:01:06Z")

</div>

Reply 2 of 2 - showing responses to asterisk queries

When called out from device to 5195749401 which tries trunk 1 (519 = basic config) due to exact matching pattern, fails, then tries trunk 2 (416 = full config) with fully open pattern

> [Jan 4 13:30:29] == Manager ‘xivo\_munin\_user’ logged on from 127.0.0.1  
> [Jan 4 13:30:29] == Manager ‘xivo\_munin\_user’ logged off from 127.0.0.1  
> [Jan 4 13:30:30] == Manager ‘xivo\_munin\_user’ logged on from 127.0.0.1  
> [Jan 4 13:30:34] == Setting global variable ‘SIPDOMAIN’ to ‘192.168.1.201’  
> [Jan 4 13:30:34] – Executing [5195749401@StokeInternalContext:1] Set(“PJSIP/rcoffice\_home-0000000d”, “XIVO\_BASE\_CONTEXT=StokeInternalContext”) in new stack  
> [Jan 4 13:30:34] – Executing [5195749401@StokeInternalContext:2] Set(“PJSIP/rcoffice\_home-0000000d”, “XIVO\_BASE\_EXTEN=5195749401”) in new stack  
> [Jan 4 13:30:34] – Executing [5195749401@StokeInternalContext:3] Gosub(“PJSIP/rcoffice\_home-0000000d”, “outcall,s,1(2,)”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:1] Set(“PJSIP/rcoffice\_home-0000000d”, “XIVO\_DSTID=2”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:2] Set(“PJSIP/rcoffice\_home-0000000d”, “XIVO\_PRESUBR\_GLOBAL\_NAME=OUTCALL”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:3] Set(“PJSIP/rcoffice\_home-0000000d”, “XIVO\_SRCNUM=5195710413”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:4] Set(“PJSIP/rcoffice\_home-0000000d”, “XIVO\_DSTNUM=5195749401”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:5] Set(“PJSIP/rcoffice\_home-0000000d”, “XIVO\_CONTEXT=StokeInternalContext”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:6] Set(“PJSIP/rcoffice\_home-0000000d”, “WAZO\_CHANNEL\_DIRECTION=to-wazo”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:7] Gosub(“PJSIP/rcoffice\_home-0000000d”, “originate-caller-id,s,1”) in new stack  
> [Jan 4 13:30:34] – Executing [s@originate-caller-id:1] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “0?:name”) in new stack  
> [Jan 4 13:30:34] – Goto (originate-caller-id,s,3)  
> [Jan 4 13:30:34] – Executing [s@originate-caller-id:3] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “0?:fix”) in new stack  
> [Jan 4 13:30:34] – Goto (originate-caller-id,s,5)  
> [Jan 4 13:30:34] – Executing [s@originate-caller-id:5] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “?:end”) in new stack  
> [Jan 4 13:30:34] – Goto (originate-caller-id,s,9)  
> [Jan 4 13:30:34] – Executing [s@originate-caller-id:9] Return(“PJSIP/rcoffice\_home-0000000d”, “”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:8] AGI(“PJSIP/rcoffice\_home-0000000d”, “agi://localhost/outgoing\_user\_set\_features”) in new stack  
> [Jan 4 13:30:34] agi://localhost/outgoing\_user\_set\_features: AGI handler ‘outgoing\_user\_set\_features’ successfully executed  
> [Jan 4 13:30:34] – \<PJSIP/rcoffice\_home-0000000d\>AGI Script agi://localhost/outgoing\_user\_set\_features completed, returning 0  
> [Jan 4 13:30:34] – Executing [s@outcall:9] Gosub(“PJSIP/rcoffice\_home-0000000d”, “wazo-setup-userevent-dial-echo,s,1”) in new stack  
> [Jan 4 13:30:34] – Executing [s@wazo-setup-userevent-dial-echo:1] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “0?:return”) in new stack  
> [Jan 4 13:30:34] – Goto (wazo-setup-userevent-dial-echo,s,3)  
> [Jan 4 13:30:34] – Executing [s@wazo-setup-userevent-dial-echo:3] Return(“PJSIP/rcoffice\_home-0000000d”, “”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:10] Gosub(“PJSIP/rcoffice\_home-0000000d”, “xivo-subroutine,s,1()”) in new stack  
> [Jan 4 13:30:34] – Executing [s@xivo-subroutine:1] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “?:nosubroutine”) in new stack  
> [Jan 4 13:30:34] – Goto (xivo-subroutine,s,4)  
> [Jan 4 13:30:34] – Executing [s@xivo-subroutine:4] Return(“PJSIP/rcoffice\_home-0000000d”, “”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:11] Gosub(“PJSIP/rcoffice\_home-0000000d”, “xivo-user\_rights\_check,s,1”) in new stack  
> [Jan 4 13:30:34] – Executing [s@xivo-user\_rights\_check:1] AGI(“PJSIP/rcoffice\_home-0000000d”, “agi://localhost/user\_set\_call\_rights”) in new stack  
> [Jan 4 13:30:34] agi://localhost/user\_set\_call\_rights: AGI handler ‘user\_set\_call\_rights’ successfully executed  
> [Jan 4 13:30:34] – \<PJSIP/rcoffice\_home-0000000d\>AGI Script agi://localhost/user\_set\_call\_rights completed, returning 0  
> [Jan 4 13:30:34] – Executing [s@xivo-user\_rights\_check:2] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “ALLOW?:error,1”) in new stack  
> [Jan 4 13:30:34] – Executing [s@xivo-user\_rights\_check:3] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “1?allow,1”) in new stack  
> [Jan 4 13:30:34] – Goto (xivo-user\_rights\_check,allow,1)  
> [Jan 4 13:30:34] – Executing [allow@xivo-user\_rights\_check:1] NoOp(“PJSIP/rcoffice\_home-0000000d”, “User allowed to make call”) in new stack  
> [Jan 4 13:30:34] – Executing [allow@xivo-user\_rights\_check:2] Return(“PJSIP/rcoffice\_home-0000000d”, “”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:12] AGI(“PJSIP/rcoffice\_home-0000000d”, “agi://localhost/check\_schedule”) in new stack  
> [Jan 4 13:30:34] agi://localhost/check\_schedule: AGI handler ‘check\_schedule’ successfully executed  
> [Jan 4 13:30:34] – \<PJSIP/rcoffice\_home-0000000d\>AGI Script agi://localhost/check\_schedule completed, returning 0  
> [Jan 4 13:30:34] – Executing [s@outcall:13] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “0?CLOSED,1”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:14] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “?:16”) in new stack  
> [Jan 4 13:30:34] – Goto (outcall,s,16)  
> [Jan 4 13:30:34] – Executing [s@outcall:16] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “PJSIP?:error,1”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:17] Set(“PJSIP/rcoffice\_home-0000000d”, “TRUNKINDEX=0”) in new stack  
> [Jan 4 13:30:34] – Executing [s@outcall:18] Goto(“PJSIP/rcoffice\_home-0000000d”, “dial,1”) in new stack  
> [Jan 4 13:30:34] – Goto (outcall,dial,1)  
> [Jan 4 13:30:34] – Executing [dial@outcall:1] Set(“PJSIP/rcoffice\_home-0000000d”, “INTERFACE=PJSIP”) in new stack  
> [Jan 4 13:30:34] – Executing [dial@outcall:2] Set(“PJSIP/rcoffice\_home-0000000d”, “TRUNKEXTEN=5195749401@5198803610”) in new stack  
> [Jan 4 13:30:34] – Executing [dial@outcall:3] Set(“PJSIP/rcoffice\_home-0000000d”, “TRUNKSUFFIX=”) in new stack  
> [Jan 4 13:30:34] – Executing [dial@outcall:4] Gosub(“PJSIP/rcoffice\_home-0000000d”, “xivo-global-subroutine,s,1”) in new stack  
> [Jan 4 13:30:34] – Executing [s@xivo-global-subroutine:1] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “1?:return”) in new stack  
> [Jan 4 13:30:34] – Executing [s@xivo-global-subroutine:2] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “OUTCALL?:return”) in new stack  
> [Jan 4 13:30:34] – Executing [s@xivo-global-subroutine:3] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “xivo-subrgbl-outcall?:return”) in new stack  
> [Jan 4 13:30:34] – Executing [s@xivo-global-subroutine:4] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “0?:return”) in new stack  
> [Jan 4 13:30:34] – Goto (xivo-global-subroutine,s,6)  
> [Jan 4 13:30:34] – Executing [s@xivo-global-subroutine:6] Return(“PJSIP/rcoffice\_home-0000000d”, “”) in new stack  
> [Jan 4 13:30:34] – Executing [dial@outcall:5] CELGenUserEvent(“PJSIP/rcoffice\_home-0000000d”, “XIVO\_OUTCALL”) in new stack  
> [Jan 4 13:30:34] – Executing [dial@outcall:6] Set(“PJSIP/rcoffice\_home-0000000d”, “CONNECTEDLINE(num,i)=5195749401”) in new stack  
> [Jan 4 13:30:34] – Executing [dial@outcall:7] Dial(“PJSIP/rcoffice\_home-0000000d”, “PJSIP/5195749401@5198803610,o(5195749401)”) in new stack  
> [Jan 4 13:30:34] – Called PJSIP/5195749401@5198803610  
> [2020-01-04 13:30:34.2083] NOTICE[10444]: res\_pjsip\_session.c:3057 new\_invite: Call from ‘4162269542’ (UDP:192.168.1.201:5060) to extension ‘5195749401’ rejected because extension not found in context ‘StokeIncallContext’.  
> [Jan 4 13:30:34] == Everyone is busy/congested at this time (1:0/0/1)  
> [Jan 4 13:30:34] – Executing [dial@outcall:8] Goto(“PJSIP/rcoffice\_home-0000000d”, “CHANUNAVAIL,1”) in new stack  
> [Jan 4 13:30:34] – Goto (outcall,CHANUNAVAIL,1)  
> [Jan 4 13:30:34] – Executing [CHANUNAVAIL@outcall:1] Goto(“PJSIP/rcoffice\_home-0000000d”, “redial,1”) in new stack  
> [Jan 4 13:30:34] – Goto (outcall,redial,1)  
> [Jan 4 13:30:34] – Executing [redial@outcall:1] Set(“PJSIP/rcoffice\_home-0000000d”, “TRUNKINDEX=1”) in new stack  
> [Jan 4 13:30:34] – Executing [redial@outcall:2] GotoIf(“PJSIP/rcoffice\_home-0000000d”, “?dial,1”) in new stack  
> [Jan 4 13:30:34] – Executing [redial@outcall:3] Playback(“PJSIP/rcoffice\_home-0000000d”, “congestion-call”) in new stack  
> [Jan 4 13:30:34] \> 0x7f741c006a20 – Strict RTP learning after remote address set to: 192.168.1.192:10002  
> [Jan 4 13:30:34] \> 0x7f741c006a20 – Strict RTP switching to RTP target address 192.168.1.192:10002 as source  
> [Jan 4 13:30:34] – \<PJSIP/rcoffice\_home-0000000d\> Playing ‘congestion-call.slin’ (language ‘en\_US’)  
> [Jan 4 13:30:40] == Manager ‘xivo\_munin\_user’ logged off from 127.0.0.1

When called out from device to 4162262143 which uses trunk 2 only (with extra confgs for provider)

> [Jan 4 13:30:40] == Manager ‘xivo\_munin\_user’ logged off from 127.0.0.1  
> [Jan 4 13:34:17] == Setting global variable ‘SIPDOMAIN’ to ‘192.168.1.201’  
> [Jan 4 13:34:17] – Executing [4162262143@StokeInternalContext:1] Set(“PJSIP/rcoffice\_home-0000000f”, “XIVO\_BASE\_CONTEXT=StokeInternalContext”) in new stack  
> [Jan 4 13:34:17] – Executing [4162262143@StokeInternalContext:2] Set(“PJSIP/rcoffice\_home-0000000f”, “XIVO\_BASE\_EXTEN=4162262143”) in new stack  
> [Jan 4 13:34:17] – Executing [4162262143@StokeInternalContext:3] Gosub(“PJSIP/rcoffice\_home-0000000f”, “outcall,s,1(3,)”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:1] Set(“PJSIP/rcoffice\_home-0000000f”, “XIVO\_DSTID=3”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:2] Set(“PJSIP/rcoffice\_home-0000000f”, “XIVO\_PRESUBR\_GLOBAL\_NAME=OUTCALL”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:3] Set(“PJSIP/rcoffice\_home-0000000f”, “XIVO\_SRCNUM=5195710413”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:4] Set(“PJSIP/rcoffice\_home-0000000f”, “XIVO\_DSTNUM=4162262143”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:5] Set(“PJSIP/rcoffice\_home-0000000f”, “XIVO\_CONTEXT=StokeInternalContext”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:6] Set(“PJSIP/rcoffice\_home-0000000f”, “WAZO\_CHANNEL\_DIRECTION=to-wazo”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:7] Gosub(“PJSIP/rcoffice\_home-0000000f”, “originate-caller-id,s,1”) in new stack  
> [Jan 4 13:34:17] – Executing [s@originate-caller-id:1] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “0?:name”) in new stack  
> [Jan 4 13:34:17] – Goto (originate-caller-id,s,3)  
> [Jan 4 13:34:17] – Executing [s@originate-caller-id:3] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “0?:fix”) in new stack  
> [Jan 4 13:34:17] – Goto (originate-caller-id,s,5)  
> [Jan 4 13:34:17] – Executing [s@originate-caller-id:5] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “?:end”) in new stack  
> [Jan 4 13:34:17] – Goto (originate-caller-id,s,9)  
> [Jan 4 13:34:17] – Executing [s@originate-caller-id:9] Return(“PJSIP/rcoffice\_home-0000000f”, “”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:8] AGI(“PJSIP/rcoffice\_home-0000000f”, “agi://localhost/outgoing\_user\_set\_features”) in new stack  
> [Jan 4 13:34:17] agi://localhost/outgoing\_user\_set\_features: AGI handler ‘outgoing\_user\_set\_features’ successfully executed  
> [Jan 4 13:34:17] – \<PJSIP/rcoffice\_home-0000000f\>AGI Script agi://localhost/outgoing\_user\_set\_features completed, returning 0  
> [Jan 4 13:34:17] – Executing [s@outcall:9] Gosub(“PJSIP/rcoffice\_home-0000000f”, “wazo-setup-userevent-dial-echo,s,1”) in new stack  
> [Jan 4 13:34:17] – Executing [s@wazo-setup-userevent-dial-echo:1] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “0?:return”) in new stack  
> [Jan 4 13:34:17] – Goto (wazo-setup-userevent-dial-echo,s,3)  
> [Jan 4 13:34:17] – Executing [s@wazo-setup-userevent-dial-echo:3] Return(“PJSIP/rcoffice\_home-0000000f”, “”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:10] Gosub(“PJSIP/rcoffice\_home-0000000f”, “xivo-subroutine,s,1()”) in new stack  
> [Jan 4 13:34:17] – Executing [s@xivo-subroutine:1] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “?:nosubroutine”) in new stack  
> [Jan 4 13:34:17] – Goto (xivo-subroutine,s,4)  
> [Jan 4 13:34:17] – Executing [s@xivo-subroutine:4] Return(“PJSIP/rcoffice\_home-0000000f”, “”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:11] Gosub(“PJSIP/rcoffice\_home-0000000f”, “xivo-user\_rights\_check,s,1”) in new stack  
> [Jan 4 13:34:17] – Executing [s@xivo-user\_rights\_check:1] AGI(“PJSIP/rcoffice\_home-0000000f”, “agi://localhost/user\_set\_call\_rights”) in new stack  
> [Jan 4 13:34:17] agi://localhost/user\_set\_call\_rights: AGI handler ‘user\_set\_call\_rights’ successfully executed  
> [Jan 4 13:34:17] – \<PJSIP/rcoffice\_home-0000000f\>AGI Script agi://localhost/user\_set\_call\_rights completed, returning 0  
> [Jan 4 13:34:17] – Executing [s@xivo-user\_rights\_check:2] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “ALLOW?:error,1”) in new stack  
> [Jan 4 13:34:17] – Executing [s@xivo-user\_rights\_check:3] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “1?allow,1”) in new stack  
> [Jan 4 13:34:17] – Goto (xivo-user\_rights\_check,allow,1)  
> [Jan 4 13:34:17] – Executing [allow@xivo-user\_rights\_check:1] NoOp(“PJSIP/rcoffice\_home-0000000f”, “User allowed to make call”) in new stack  
> [Jan 4 13:34:17] – Executing [allow@xivo-user\_rights\_check:2] Return(“PJSIP/rcoffice\_home-0000000f”, “”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:12] AGI(“PJSIP/rcoffice\_home-0000000f”, “agi://localhost/check\_schedule”) in new stack  
> [Jan 4 13:34:17] agi://localhost/check\_schedule: AGI handler ‘check\_schedule’ successfully executed  
> [Jan 4 13:34:17] – \<PJSIP/rcoffice\_home-0000000f\>AGI Script agi://localhost/check\_schedule completed, returning 0  
> [Jan 4 13:34:17] – Executing [s@outcall:13] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “0?CLOSED,1”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:14] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “?:16”) in new stack  
> [Jan 4 13:34:17] – Goto (outcall,s,16)  
> [Jan 4 13:34:17] – Executing [s@outcall:16] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “PJSIP?:error,1”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:17] Set(“PJSIP/rcoffice\_home-0000000f”, “TRUNKINDEX=0”) in new stack  
> [Jan 4 13:34:17] – Executing [s@outcall:18] Goto(“PJSIP/rcoffice\_home-0000000f”, “dial,1”) in new stack  
> [Jan 4 13:34:17] – Goto (outcall,dial,1)  
> [Jan 4 13:34:17] – Executing [dial@outcall:1] Set(“PJSIP/rcoffice\_home-0000000f”, “INTERFACE=PJSIP”) in new stack  
> [Jan 4 13:34:17] – Executing [dial@outcall:2] Set(“PJSIP/rcoffice\_home-0000000f”, “TRUNKEXTEN=4162262143@4162269542”) in new stack  
> [Jan 4 13:34:17] – Executing [dial@outcall:3] Set(“PJSIP/rcoffice\_home-0000000f”, “TRUNKSUFFIX=”) in new stack  
> [Jan 4 13:34:17] – Executing [dial@outcall:4] Gosub(“PJSIP/rcoffice\_home-0000000f”, “xivo-global-subroutine,s,1”) in new stack  
> [Jan 4 13:34:17] – Executing [s@xivo-global-subroutine:1] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “1?:return”) in new stack  
> [Jan 4 13:34:17] – Executing [s@xivo-global-subroutine:2] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “OUTCALL?:return”) in new stack  
> [Jan 4 13:34:17] – Executing [s@xivo-global-subroutine:3] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “xivo-subrgbl-outcall?:return”) in new stack  
> [Jan 4 13:34:17] – Executing [s@xivo-global-subroutine:4] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “0?:return”) in new stack  
> [Jan 4 13:34:17] – Goto (xivo-global-subroutine,s,6)  
> [Jan 4 13:34:17] – Executing [s@xivo-global-subroutine:6] Return(“PJSIP/rcoffice\_home-0000000f”, “”) in new stack  
> [Jan 4 13:34:17] – Executing [dial@outcall:5] CELGenUserEvent(“PJSIP/rcoffice\_home-0000000f”, “XIVO\_OUTCALL”) in new stack  
> [Jan 4 13:34:17] – Executing [dial@outcall:6] Set(“PJSIP/rcoffice\_home-0000000f”, “CONNECTEDLINE(num,i)=4162262143”) in new stack  
> [Jan 4 13:34:17] – Executing [dial@outcall:7] Dial(“PJSIP/rcoffice\_home-0000000f”, “PJSIP/4162262143@4162269542,o(4162262143)”) in new stack  
> [Jan 4 13:34:17] – Called PJSIP/4162262143@4162269542  
> [2020-01-04 13:34:17.3109] NOTICE[6707]: res\_pjsip\_session.c:3057 new\_invite: Call from ‘4162269542’ (UDP:192.168.1.201:5060) to extension ‘4162262143’ rejected because extension not found in context ‘StokeIncallContext’.  
> [Jan 4 13:34:17] == Everyone is busy/congested at this time (1:0/0/1)  
> [Jan 4 13:34:17] – Executing [dial@outcall:8] Goto(“PJSIP/rcoffice\_home-0000000f”, “CHANUNAVAIL,1”) in new stack  
> [Jan 4 13:34:17] – Goto (outcall,CHANUNAVAIL,1)  
> [Jan 4 13:34:17] – Executing [CHANUNAVAIL@outcall:1] Goto(“PJSIP/rcoffice\_home-0000000f”, “redial,1”) in new stack  
> [Jan 4 13:34:17] – Goto (outcall,redial,1)  
> [Jan 4 13:34:17] – Executing [redial@outcall:1] Set(“PJSIP/rcoffice\_home-0000000f”, “TRUNKINDEX=1”) in new stack  
> [Jan 4 13:34:17] – Executing [redial@outcall:2] GotoIf(“PJSIP/rcoffice\_home-0000000f”, “?dial,1”) in new stack  
> [Jan 4 13:34:17] – Executing [redial@outcall:3] Playback(“PJSIP/rcoffice\_home-0000000f”, “congestion-call”) in new stack  
> [Jan 4 13:34:17] \> 0x7f7460035a60 – Strict RTP learning after remote address set to: 192.168.1.192:10002  
> [Jan 4 13:34:17] \> 0x7f7460035a60 – Strict RTP switching to RTP target address 192.168.1.192:10002 as source  
> [Jan 4 13:34:17] – \<PJSIP/rcoffice\_home-0000000f\> Playing ‘congestion-call.slin’ (language ‘en\_US’)  
> [Jan 4 13:35:01] == Manager ‘xivo\_munin\_user’ logged on from 127.0.0.1

Call in to 4162269542 (with extra confgs for provider) which is directed to single extension softphone (which is connected and on hook) - gets busy signal

> [Jan 4 13:36:45] == Setting global variable ‘SIPDOMAIN’ to ‘192.168.1.201’  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:1] NoOp(“PJSIP/4162269542-00000011”, “”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:2] GotoIf(“PJSIP/4162269542-00000011”, “1?:not-pjsip”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:3] GotoIf(“PJSIP/4162269542-00000011”, “1?:error-loop”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:4] Set(“PJSIP/4162269542-00000011”, “XIVO\_DID\_NEXT\_EXTEN=s”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:5] Set(“PJSIP/4162269542-00000011”, “XIVO\_FROM\_S=1”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:6] Goto(“PJSIP/4162269542-00000011”, “StokeIncallContext,s,1”) in new stack  
> [Jan 4 13:36:45] – Goto (StokeIncallContext,s,1)  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:1] NoOp(“PJSIP/4162269542-00000011”, “”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:2] GotoIf(“PJSIP/4162269542-00000011”, “1?:not-pjsip”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:3] GotoIf(“PJSIP/4162269542-00000011”, “0?:error-loop”) in new stack  
> [Jan 4 13:36:45] – Goto (StokeIncallContext,s,10)  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:10] NoOp(“PJSIP/4162269542-00000011”, “”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:11] Log(“PJSIP/4162269542-00000011”, “ERROR, Dialplan loop detected. Got PJSIP header To: sip:s@192.168.1.201”) in new stack  
> [2020-01-04 13:36:45.9759] ERROR[19190][C-0000000b]: Ext. s:11 @ StokeIncallContext: Dialplan loop detected. Got PJSIP header To: sip:s@192.168.1.201  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:12] Hangup(“PJSIP/4162269542-00000011”, “”) in new stack  
> [Jan 4 13:36:45] == Spawn extension (StokeIncallContext, s, 12) exited non-zero on ‘PJSIP/4162269542-00000011’

call to 5198803610 (basic config) which is directed to User which has two lines on it - gets response number not assigned

> [Jan 4 13:36:45] == Setting global variable ‘SIPDOMAIN’ to ‘192.168.1.201’  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:1] NoOp(“PJSIP/4162269542-00000011”, “”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:2] GotoIf(“PJSIP/4162269542-00000011”, “1?:not-pjsip”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:3] GotoIf(“PJSIP/4162269542-00000011”, “1?:error-loop”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:4] Set(“PJSIP/4162269542-00000011”, “XIVO\_DID\_NEXT\_EXTEN=s”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:5] Set(“PJSIP/4162269542-00000011”, “XIVO\_FROM\_S=1”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:6] Goto(“PJSIP/4162269542-00000011”, “StokeIncallContext,s,1”) in new stack  
> [Jan 4 13:36:45] – Goto (StokeIncallContext,s,1)  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:1] NoOp(“PJSIP/4162269542-00000011”, “”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:2] GotoIf(“PJSIP/4162269542-00000011”, “1?:not-pjsip”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:3] GotoIf(“PJSIP/4162269542-00000011”, “0?:error-loop”) in new stack  
> [Jan 4 13:36:45] – Goto (StokeIncallContext,s,10)  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:10] NoOp(“PJSIP/4162269542-00000011”, “”) in new stack  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:11] Log(“PJSIP/4162269542-00000011”, “ERROR, Dialplan loop detected. Got PJSIP header To: sip:s@192.168.1.201”) in new stack  
> [2020-01-04 13:36:45.9759] ERROR[19190][C-0000000b]: Ext. s:11 @ StokeIncallContext: Dialplan loop detected. Got PJSIP header To: sip:s@192.168.1.201  
> [Jan 4 13:36:45] – Executing [s@StokeIncallContext:12] Hangup(“PJSIP/4162269542-00000011”, “”) in new stack  
> [Jan 4 13:36:45] == Spawn extension (StokeIncallContext, s, 12) exited non-zero on ‘PJSIP/4162269542-00000011’  
> [2020-01-04 13:37:29.6741] NOTICE[6707]: res\_pjsip/pjsip\_distributor.c:676 log\_failed\_request: Request ‘INVITE’ from ‘“RICHARD CANTIN” sip:5195749401@216.254.220.21’ failed for ‘216.254.220.21:5060’ (callid: [39d015d2078aa54046eb3ae3766e5ce1@216.254.220.21](mailto:39d015d2078aa54046eb3ae3766e5ce1@216.254.220.21)) - Failed to authenticate  
> [2020-01-04 13:37:29.6867] NOTICE[6707]: res\_pjsip/pjsip\_distributor.c:676 log\_failed\_request: Request ‘INVITE’ from ‘“RICHARD CANTIN” sip:5195749401@216.254.220.21’ failed for ‘216.254.220.21:5060’ (callid: [39d015d2078aa54046eb3ae3766e5ce1@216.254.220.21](mailto:39d015d2078aa54046eb3ae3766e5ce1@216.254.220.21)) - Failed to authenticate  
> [2020-01-04 13:37:29.6994] NOTICE[6707]: res\_pjsip/pjsip\_distributor.c:676 log\_failed\_request: Request ‘INVITE’ from ‘“RICHARD CANTIN” sip:5195749401@216.254.220.21’ failed for ‘216.254.220.21:5060’ (callid: [39d015d2078aa54046eb3ae3766e5ce1@216.254.220.21](mailto:39d015d2078aa54046eb3ae3766e5ce1@216.254.220.21)) - Failed to authenticate  
> [2020-01-04 13:37:30.1201] NOTICE[6707]: res\_pjsip/pjsip\_distributor.c:676 log\_failed\_request: Request ‘INVITE’ from ‘“RICHARD CANTIN” sip:5195749401@216.254.220.21’ failed for ‘216.254.220.21:5060’ (callid: [5489d8ce2a9094494ae7f05a25c5ffe8@216.254.220.21](mailto:5489d8ce2a9094494ae7f05a25c5ffe8@216.254.220.21)) - Failed to authenticate  
> [2020-01-04 13:37:30.1323] NOTICE[6707]: res\_pjsip/pjsip\_distributor.c:676 log\_failed\_request: Request ‘INVITE’ from ‘“RICHARD CANTIN” sip:5195749401@216.254.220.21’ failed for ‘216.254.220.21:5060’ (callid: [5489d8ce2a9094494ae7f05a25c5ffe8@216.254.220.21](mailto:5489d8ce2a9094494ae7f05a25c5ffe8@216.254.220.21)) - Failed to authenticate  
> [2020-01-04 13:37:30.1439] NOTICE[6707]: res\_pjsip/pjsip\_distributor.c:676 log\_failed\_request: Request ‘INVITE’ from ‘“RICHARD CANTIN” sip:5195749401@216.254.220.21’ failed for ‘216.254.220.21:5060’ (callid: [5489d8ce2a9094494ae7f05a25c5ffe8@216.254.220.21](mailto:5489d8ce2a9094494ae7f05a25c5ffe8@216.254.220.21)) - Failed to authenticate

---

<div class="post-metadata">

**Author:** ![Ramblin](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/ramblin/32/34_2.png) [@Ramblin](https://wazo-platform.discourse.group/u/Ramblin)\
**Post date:** [January 5, 2020, 4:38pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/6 "2020-01-05T16:38:01Z")

</div>

I have edited the configuration for trunk1 to match trunk 2 so both now have all the configs required by the provider - as best as I can tell. Those extra configs for each trunk are:

> buggymwi: no  
> nat: force\_rport,comedia  
> insecure: port,invite  
> rtptimeout: 60  
> rtpholdtimeout: 300  
> allowoverlap: no  
> allowtransfer: no  
> progressinband: no  
> disallow: all  
> allow: ulaw

So both now come back with busy when called in to and “busy or unreachable” when called out.

Both are registered and both are properly triggered by the dialplan.

But neither can call out or in - just internal to internal calls work. (as before)

---

<div class="post-metadata">

**Author:** ![Ramblin](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/ramblin/32/34_2.png) [@Ramblin](https://wazo-platform.discourse.group/u/Ramblin)\
**Post date:** [January 6, 2020, 1:14pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/7 "2020-01-06T13:14:20Z")

</div>

I added a trunk to another provider and tested it for incall and outcall.

Exactly same result.

I am willing to bet it is some simple setting/configuration I am missing (hopefully) but cannot for the life of me figure out what it is.

Any suggestions appreciated.

---

<div class="post-metadata">

**Author:** ![Ramblin](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/ramblin/32/34_2.png) [@Ramblin](https://wazo-platform.discourse.group/u/Ramblin)\
**Post date:** [January 8, 2020, 9:40am UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/8 "2020-01-08T09:40:29Z")

</div>

It has been suggested that the issue with being able to make calls out or accept calls in might have something to do with one (or combination) of:

1. Firewall
2. Port Forwarding
3. NAT

Re 1), I have disabled my firewall on this, my development server, so it is not that.

Re 2) I have not forwarded any Ports through my router. I am not accepting connections from any location other than the Trunk Provider(s) and since I am reaching out to them, I did not think I needed to forward any Ports. I have the same setup now with my existing PBX and it is working fine. However, if the Wazo setup requires any Ports forwarded, can you let me know?

Re 3) I have added to the SIP General Settings the following:  
nat =\> force\_rport,comedia  
externip =\> {my actual public IP}  
localnet =\> 192.168.1.0/255.255.255.0

Which is in addition to the Options I added in the Trunks for the one provider as per their specs:  
buggymwi: no  
nat: force\_rport,comedia  
insecure: port,invite  
rtptimeout: 60  
rtpholdtimeout: 300  
allowoverlap: no  
allowtransfer: no  
progressinband: no  
disallow: all  
allow: ulaw  
directmedia: no

And I also connected Wazo to another Trunk provider I use without the above additonal Trunk Options

Unfortunately, no change for either Trunk povider

Internal calls work fine  
Calls In or Calls out come back with error message Unreachable or Busy

Any suggestions are appreciated

---

<div class="post-metadata">

**Author:** ![Ramblin](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/ramblin/32/34_2.png) [@Ramblin](https://wazo-platform.discourse.group/u/Ramblin)\
**Post date:** [January 13, 2020, 3:03pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/9 "2020-01-13T15:03:46Z")

</div>

I am coming to the conclusion that it might be a NAT issue but would sure appreciate some guidance.

When I activate

> asterisk -r

and call out, at the end of the output are the lines

> ```
> [Jan 13 09:53:05] > 0x7fa91c007a40 -- Strict RTP learning after remote address set > to: 192.168.1.149:40006
> [Jan 13 09:53:05] > 0x7fa91c007a40 -- Strict RTP switching to RTP target address 192.168.1.149:40006 as source
> 
> ```

Two things seem wrong with this

1. I think the IP address should be my public ip address, not my LAN IP address
2. I think I need rtp\_symmetric , not rtpstrict but the system keeps activating rtp strict.

I am also somewhat confused with the entries in SIP General settings. When I look at  
[https://wiki.asterisk.org/wiki/display/AST/Migrating+from+chan\_sip+to+res\_pjsip](https://wiki.asterisk.org/wiki/display/AST/Migrating+from+chan_sip+to+res_pjsip)  
the instructions for how to configure pjsip instead of chan\_sip say for nat declarations, we no longer use

> nat= no or nat = force\_rport,comedia or nat= auto\_force\_rport

but instead now use a combination of these three settings to properly setup nat

> force\_rport: yes  
> rewrite\_contact: yes  
> rtp\_symmetric: yes

but I see in SIP General Settings that we have

> nat = auto\_force\_rport

So I am now not sure what conventions / protocols I should be using for my configuration settings.

I have a nat behind a static IP for my server.

I think i need to stop using rtpstrict.

I think I need to use pjsip configuration options.

But I need help figuring out what to do.

Any ideas?

---

<div class="post-metadata">

**Author:** ![Ramblin](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/ramblin/32/34_2.png) [@Ramblin](https://wazo-platform.discourse.group/u/Ramblin)\
**Post date:** [January 29, 2020, 1:48pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/10 "2020-01-29T13:48:42Z")

</div>

If you’ve actually read this far, congratulations, you are a patient person. 🙂  
So the issues were multiple in my case.

1. In the Trunk setup, I had listed as my Host, the IP address of the Wazo server when in fact that is supposed to be the IP addres / FQDN of the trunk provider
2. In the Trunk setup, I had used teh UserName/Password of the endpoint on the Wazo server when you are supposed to use the UserName/Password of the trunk provider
3. In the Trunk setup - Register (tab) I had not entered a callback Extension and you are supposed to put the DID in there
4. In the Trunk setup - Options, for my trunk provider, I had to add:
  - fromuser: username provided by trunk provider
  - fromdoman: the domain of the trunk provider

The NAT settings can be left as nat=force\_rport,comedia and Wazo will translate as required to pjsip labels

All is now working

Now to finish with groups, scheduling, paging, … and document and share the document (in my spare time)

Thank you VERY MUCH to all who helped

---

<div class="post-metadata">

**Author:** ![Miker](https://avatars.discourse-cdn.com/v4/letter/m/3da27b/32.png) [@Miker](https://wazo-platform.discourse.group/u/Miker)\
**Post date:** [January 18, 2021, 12:35pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/11 "2021-01-18T12:35:12Z")

</div>

Hi there

Thanks for your helpful post, so far my internal and outbound calls are working perfectly but inbound call are not working:

My DID is 2191323555 and here is the msg I receive when I have an incoming call:

[Jan 18 15:59:49] – Executing [2191323555@to-provider:1] Set(“PJSIP/provider-0000004c”, “XIVO\_BASE\_CONTEXT=to-provider”) in new stack  
[Jan 18 15:59:49] – Executing [2191323555@to-provider:2] Set(“PJSIP/provider-0000004c”, “XIVO\_BASE\_EXTEN=2191323555”) in new stack  
[Jan 18 15:59:49] – Executing [2191323555@to-provider:3] Gosub(“PJSIP/provider-0000004c”, “outcall,s,1(1,)”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:1] Set(“PJSIP/provider-0000004c”, “XIVO\_DSTID=1”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:2] Set(“PJSIP/provider-0000004c”, “XIVO\_PRESUBR\_GLOBAL\_NAME=OUTCALL”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:3] Set(“PJSIP/provider-0000004c”, “XIVO\_SRCNUM=88675889”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:4] Set(“PJSIP/provider-0000004c”, “XIVO\_DSTNUM=2191323555”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:5] Set(“PJSIP/provider-0000004c”, “XIVO\_CONTEXT=to-provider”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:6] Set(“PJSIP/provider-0000004c”, “WAZO\_CHANNEL\_DIRECTION=to-wazo”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:7] Gosub(“PJSIP/provider-0000004c”, “originate-caller-id,s,1”) in new stack  
[Jan 18 15:59:49] – Executing [s@originate-caller-id:1] GotoIf(“PJSIP/provider-0000004c”, “0?:name”) in new stack  
[Jan 18 15:59:49] – Goto (originate-caller-id,s,3)  
[Jan 18 15:59:49] – Executing [s@originate-caller-id:3] GotoIf(“PJSIP/provider-0000004c”, “0?:fix”) in new stack  
[Jan 18 15:59:49] – Goto (originate-caller-id,s,5)  
[Jan 18 15:59:49] – Executing [s@originate-caller-id:5] GotoIf(“PJSIP/provider-0000004c”, “?:end”) in new stack  
[Jan 18 15:59:49] – Goto (originate-caller-id,s,9)  
[Jan 18 15:59:49] – Executing [s@originate-caller-id:9] Return(“PJSIP/provider-0000004c”, “”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:8] AGI(“PJSIP/provider-0000004c”, “agi://localhost/outgoing\_user\_set\_features”) in new stack  
[Jan 18 15:59:49] agi://localhost/outgoing\_user\_set\_features: res [‘459a433d-c388-42af-84bf-467d8fbef4e2’, None, None]  
[Jan 18 15:59:49] agi://localhost/outgoing\_user\_set\_features: AGI handler ‘outgoing\_user\_set\_features’ successfully executed  
[Jan 18 15:59:49] – \<PJSIP/provider-0000004c\>AGI Script agi://localhost/outgoing\_user\_set\_features completed, returning 0  
[Jan 18 15:59:49] – Executing [s@outcall:9] Gosub(“PJSIP/provider-0000004c”, “wazo-setup-userevent-dial-echo,s,1”) in new stack  
[Jan 18 15:59:49] – Executing [s@wazo-setup-userevent-dial-echo:1] GotoIf(“PJSIP/provider-0000004c”, “0?:return”) in new stack  
[Jan 18 15:59:49] – Goto (wazo-setup-userevent-dial-echo,s,3)  
[Jan 18 15:59:49] – Executing [s@wazo-setup-userevent-dial-echo:3] Return(“PJSIP/provider-0000004c”, “”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:10] Gosub(“PJSIP/provider-0000004c”, “xivo-subroutine,s,1()”) in new stack  
[Jan 18 15:59:49] – Executing [s@xivo-subroutine:1] GotoIf(“PJSIP/provider-0000004c”, “?:nosubroutine”) in new stack  
[Jan 18 15:59:49] – Goto (xivo-subroutine,s,4)  
[Jan 18 15:59:49] – Executing [s@xivo-subroutine:4] Return(“PJSIP/provider-0000004c”, “”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:11] Gosub(“PJSIP/provider-0000004c”, “xivo-user\_rights\_check,s,1”) in new stack  
[Jan 18 15:59:49] – Executing [s@xivo-user\_rights\_check:1] AGI(“PJSIP/provider-0000004c”, “agi://localhost/user\_set\_call\_rights”) in new stack  
[Jan 18 15:59:49] agi://localhost/user\_set\_call\_rights: AGI handler ‘user\_set\_call\_rights’ successfully executed  
[Jan 18 15:59:49] – \<PJSIP/provider-0000004c\>AGI Script agi://localhost/user\_set\_call\_rights completed, returning 0  
[Jan 18 15:59:49] – Executing [s@xivo-user\_rights\_check:2] GotoIf(“PJSIP/provider-0000004c”, “ALLOW?:error,1”) in new stack  
[Jan 18 15:59:49] – Executing [s@xivo-user\_rights\_check:3] GotoIf(“PJSIP/provider-0000004c”, “1?allow,1”) in new stack  
[Jan 18 15:59:49] – Goto (xivo-user\_rights\_check,allow,1)  
[Jan 18 15:59:49] – Executing [allow@xivo-user\_rights\_check:1] NoOp(“PJSIP/provider-0000004c”, “User allowed to make call”) in new stack  
[Jan 18 15:59:49] – Executing [allow@xivo-user\_rights\_check:2] Return(“PJSIP/provider-0000004c”, “”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:12] AGI(“PJSIP/provider-0000004c”, “agi://localhost/check\_schedule”) in new stack  
[Jan 18 15:59:49] agi://localhost/check\_schedule: AGI handler ‘check\_schedule’ successfully executed  
[Jan 18 15:59:49] – \<PJSIP/provider-0000004c\>AGI Script agi://localhost/check\_schedule completed, returning 0  
[Jan 18 15:59:49] – Executing [s@outcall:13] GotoIf(“PJSIP/provider-0000004c”, “0?CLOSED,1”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:14] GotoIf(“PJSIP/provider-0000004c”, “0?:no-recording”) in new stack  
[Jan 18 15:59:49] – Goto (outcall,s,17)  
[Jan 18 15:59:49] – Executing [s@outcall:17] GotoIf(“PJSIP/provider-0000004c”, “PJSIP?:error,1”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:18] Set(“PJSIP/provider-0000004c”, “TRUNKINDEX=0”) in new stack  
[Jan 18 15:59:49] – Executing [s@outcall:19] Goto(“PJSIP/provider-0000004c”, “dial,1”) in new stack  
[Jan 18 15:59:49] – Goto (outcall,dial,1)  
[Jan 18 15:59:49] – Executing [dial@outcall:1] Set(“PJSIP/provider-0000004c”, “INTERFACE=PJSIP”) in new stack  
[Jan 18 15:59:49] – Executing [dial@outcall:2] Set(“PJSIP/provider-0000004c”, “TRUNKEXTEN=2191323555@provider”) in new stack  
[Jan 18 15:59:49] – Executing [dial@outcall:3] Set(“PJSIP/provider-0000004c”, “TRUNKSUFFIX=”) in new stack  
[Jan 18 15:59:49] – Executing [dial@outcall:4] Gosub(“PJSIP/provider-0000004c”, “xivo-global-subroutine,s,1”) in new stack  
[Jan 18 15:59:49] – Executing [s@xivo-global-subroutine:1] GotoIf(“PJSIP/provider-0000004c”, “1?:return”) in new stack  
[Jan 18 15:59:49] – Executing [s@xivo-global-subroutine:2] GotoIf(“PJSIP/provider-0000004c”, “OUTCALL?:return”) in new stack  
[Jan 18 15:59:49] – Executing [s@xivo-global-subroutine:3] GotoIf(“PJSIP/provider-0000004c”, “xivo-subrgbl-outcall?:return”) in new stack  
[Jan 18 15:59:49] – Executing [s@xivo-global-subroutine:4] GotoIf(“PJSIP/provider-0000004c”, “0?:return”) in new stack  
[Jan 18 15:59:49] – Goto (xivo-global-subroutine,s,6)  
[Jan 18 15:59:49] – Executing [s@xivo-global-subroutine:6] Return(“PJSIP/provider-0000004c”, “”) in new stack  
[Jan 18 15:59:49] – Executing [dial@outcall:5] CELGenUserEvent(“PJSIP/provider-0000004c”, “XIVO\_OUTCALL”) in new stack  
[Jan 18 15:59:49] – Executing [dial@outcall:6] Set(“PJSIP/provider-0000004c”, “CONNECTEDLINE(num,i)=2191323555”) in new stack  
[Jan 18 15:59:49] – Executing [dial@outcall:7] Dial(“PJSIP/provider-0000004c”, “PJSIP/2191323555@provider,o(2191323555)”) in new stack  
[Jan 18 15:59:49] – Called PJSIP/2191323555@provider  
[Jan 18 15:59:50] == Everyone is busy/congested at this time (1:0/0/1)  
[Jan 18 15:59:50] – Executing [dial@outcall:8] Goto(“PJSIP/provider-0000004c”, “CHANUNAVAIL,1”) in new stack  
[Jan 18 15:59:50] – Goto (outcall,CHANUNAVAIL,1)  
[Jan 18 15:59:50] – Executing [CHANUNAVAIL@outcall:1] Goto(“PJSIP/provider-0000004c”, “redial,1”) in new stack  
[Jan 18 15:59:50] – Goto (outcall,redial,1)  
[Jan 18 15:59:50] – Executing [redial@outcall:1] Set(“PJSIP/provider-0000004c”, “TRUNKINDEX=1”) in new stack  
[Jan 18 15:59:50] – Executing [redial@outcall:2] GotoIf(“PJSIP/provider-0000004c”, “?dial,1”) in new stack  
[Jan 18 15:59:50] – Executing [redial@outcall:3] Playback(“PJSIP/provider-0000004c”, “congestion-call”) in new stack  
[Jan 18 15:59:50] \> 0x355a080 – Strict RTP learning after remote address set to: 185.73.1.2:26370  
[Jan 18 15:59:50] – \<PJSIP/provider-0000004c\> Playing ‘congestion-call.slin’ (language ‘en\_US’)  
[Jan 18 15:59:50] \> 0x355a080 – Strict RTP switching to RTP target address 185.73.1.2:26370 as source  
[Jan 18 16:00:02] == Manager ‘xivo\_munin\_user’ logged on from 127.0.0.1

Any thoughts on whats is going on?

Thanks

---

<div class="post-metadata">

**Author:** ![Ramblin](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/ramblin/32/34_2.png) [@Ramblin](https://wazo-platform.discourse.group/u/Ramblin)\
**Post date:** [January 18, 2021, 12:54pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/12 "2021-01-18T12:54:49Z")

</div>

I’m no expert at reading asterisk debug outputs but it appears as though this is a log of an outbound, not an inbound call.

Have you setup your inbound and outbound contexts properly?

Also, when you define an incall, are you putting an underscore “\_” before your definition (ie \_NXXXXXXXXX instead of NXXXXXXXXX)? Putting the \_ in front tells Wazo the definition is a patter. Without the \_ , Wazo interprets your definition literally and is waiting for someone to dial in with a number that will not happen (NXXXXXXXXX)

---

<div class="post-metadata">

**Author:** ![Miker](https://avatars.discourse-cdn.com/v4/letter/m/3da27b/32.png) [@Miker](https://wazo-platform.discourse.group/u/Miker)\
**Post date:** [January 18, 2021, 1:14pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/13 "2021-01-18T13:14:50Z")

</div>

I followed this article to create my contexts:

[https://sparrow.b5.pm/docs/quick-start](https://sparrow.b5.pm/docs/quick-start)

Is that the right way of setting them up?

---

<div class="post-metadata">

**Author:** ![quintana](https://yyz2.discourse-cdn.com/free1/user_avatar/wazo-platform.discourse.group/quintana/32/916_2.png) [@quintana](https://wazo-platform.discourse.group/u/quintana)\
**Post date:** [January 19, 2021, 1:10am UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/14 "2021-01-19T01:10:54Z")

</div>

The issue has been solved in our mattermost. I don’t know how exactly, but if you can share how you solve it, it would be nice.Thank you!

---

<div class="post-metadata">

**Author:** ![Miker](https://avatars.discourse-cdn.com/v4/letter/m/3da27b/32.png) [@Miker](https://wazo-platform.discourse.group/u/Miker)\
**Post date:** [January 19, 2021, 2:09pm UTC](https://wazo-platform.discourse.group/t/web-gui-adding-trunks-with-inbound-and-outbound-routes/125/15 "2021-01-19T14:09:09Z")

</div>

It was a misconfiguration in the instructions from my provider. All good now.

Thanks
