FreePBX receives 486 Busy from endpoints but then sends to our provider as 503 Service Unavailable

Yes correct, straight to the SBC :slight_smile:

Can you post a set of logs related to the first bullet point? That one seems like it should be working.

Yeah sure - what ring strategy? In essence, we want the extention to be in DND so that the Teams extension can send the busy tone right?

Maybe you could simplify the testing just by direct-dialing your Teams extension from an internal phone so that the call goes through the outbound route & SBC.

1 Like

I did a simple test, creating a Misc Destination pointing to +1 718 351 9970 (a test number that should always return a 486), then configured an Inbound Route to point a DID at the Misc Destination.

Upon calling the DID, Asterisk got a 486 from the outbound leg attempt, and correctly sent a 486 status to the incoming trunk.

Are your Teams agents dedicated to your system? If so and if possible, set them up to appear as remote extensions. That way, Asterisk keeps track of the state internally; i.e. if the user is on another call (from a queue or otherwise), the system knows he’s busy and will skip him for a queue call.

Can you please give us an overview of the system? You are in UK but the called number is in Nürnberg. Are you supporting a PBX in Germany, or is this a complex multi-national setup where there are multiple queues, including one with German speaking agents, who may also be members of other queues?

1 Like

So if I’m looking at all this right, I see a bunch of calls coming in from the PSTN or externally to the PBX. They are hitting the from-pstn context and then being sent to the SBC trunk it looks like.

[2021-02-09 21:41:50] VERBOSE[57644][C-00000b3c] app_dial.c: Everyone is busy/congested at this time (1:0/1/0) <-- NOTE IT SAYS BUSY/CONGESTED which means it could be one or the other.

And if you follow the dialplan another 6 lines after that one you’ll see:

[2021-02-09 21:41:49] VERBOSE[57644][C-00000b3c] app_dial.c: Called PJSIP/+499119380003@fronerisbc
[2021-02-09 21:41:50] VERBOSE[57644][C-00000b3c] app_dial.c: PJSIP/fronerisbc-0000168a is ringing
[2021-02-09 21:41:50] VERBOSE[57644][C-00000b3c] app_dial.c: PJSIP/fronerisbc-0000168a is ringing
[2021-02-09 21:41:50] VERBOSE[57644][C-00000b3c] app_dial.c: Everyone is busy/congested at this time (1:0/1/0)
– snip 6 lines —
[2021-02-09 21:41:50] VERBOSE[57644][C-00000b3c] pbx.c: Executing [s@crm-hangup:2] NoOp(“PJSIP/to_telefonica_primary-00001689”, “HANGUP CAUSE: 34”) in new stack

In other worse the SBC returned a 503 to the PBX. There’s your 503 error.

1 Like

In all honesty, I am not sure if it is the SBC sending the 503 like @BlazeStudios mentions below. It is entirely possible but in the packet captures I take, I see it as a 486.

In any case, @billsimon instead of setting it up as a direct find me follow me on the primary extension, we changed it to find me follow me onto a virtual extension.

The virtual extension also has find me follow me setup to the teams DDI, so in this instance:

PSTN → Extension with follow me to virtual extension → PJSIP device and Teams ring simultaneously.

When Teams sends 486 busy, this is relayed by our PBX through to our provider and as such, we get the busy tone as we wanted.

Logically, I think it makes sense because freepbx can relay busy if it comes from an extension in the system. With the original setup, when we forward the call straight out of a sip trunk, I think the PBX cant keep track so when receiving a busy for something it is not entirely aware of, I think this was causing the 503 to be sent to the provider.

This is how I think it works, but I could be entirely wrong. It works with a virtual extension being the intermediary between our PBX and the SBC and it kind of makes logical sense.

Thanks for your help :slight_smile:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.