Howto:Handle overlapping or partial Extensions: Difference between revisions

From innovaphone wiki
Jump to navigation Jump to search
(New page: ==Applies To== This information applies to * all gateways, Firmware V8 or later <!-- Keywords: different length of DID DDI PSTN extensions migration numbering plan --> ==More Information...)
 
 
(5 intermediate revisions by 2 users not shown)
Line 6: Line 6:
<!-- Keywords: different length of DID DDI PSTN extensions migration numbering plan -->
<!-- Keywords: different length of DID DDI PSTN extensions migration numbering plan -->
==More Information==
==More Information==
Sometimes a customer wants to be reachable from the PSTN using digit extension with different length, that also overlap. In this article we will assume that the PBX uses 4 digit extension, while 3-digit extension should also be dial-able from the PSTN. However any other digit-length combination can be used.
When customers migrate their PBX numbering plan from shorter to longer extension (say, from 3 to 4-digit extensions), there is a need to map the old shorter extension to the corresponding new longer extensions.  As the PBX does not allow to create objects with overlapping ''Number'' properties (e.g. two objects with ''Number''s <code>200</code> and <code>2009</code>, this must be done in the gateway layer of the corresponding trunk access.
 
In this article we will assume that the PBX uses 4 digit extension, while 3-digit extension should also be dial-able from the PSTN. However any other digit-length combination can be used.


===Problem Details===
===Problem Details===
Since you cannot have overlapping numbers in the PBX(e.g. object with number 200 and another object with number 2001). You will have to use in the PBX a different number(e.g. instead of 200 we use 2009) and map the numbers correctly using the Relay(200 -> 2009). The first idea to have an incoming map matching the 4 digit extensions and then one for the 3 digit extensions, will not work.  
Since you cannot have overlapping numbers in the PBX, you will have to use different numbers (e.g. instead of 200 we use 2009) in the PBX and map the numbers correctly using the Relay (200 -> 2009).  


To better understand the issue, here a simplified example for the routing table:
Unfortunately, the obvious idea to have an incoming map matching the 4 digit extensions (<code>....-></code>) and following that one for the 3 digit extensions (<code>...->9</code>), will not work. This is because a 3-digit caller will hang in the first map forever, as the gateway waits for following digits, which will never come.
PRIx CDPN:2001 -> CDPN:2001 to RPx
PRIx CDPN:200 -> CDPN:2009 to RPx


Also, swapping the order of the routing table entries will not help either, as then the first map will also match if the caller wants to dial 2001, sending the call to the PBX with the wrong CDPN.
===Resolution===
We will route calls from the PSTN to the PBX and try to find a matching extension. Short 3 digit extensions, will trigger an 'Incomplete' - Timeout at the ''Trunk Line'' object, which we will use to reroute such calls back to the ''Gateway'' level.  Here we arrange for the call to be disconnected with a so-called ''rerouting cause'' (see [[Reference:Rerouting_Causes]]).  Because of this, the disconnected call will fall back to the PBX and from there back to the ''Gateway'' level (that is, to the first route sending the call from your trunk interface to the PBX).  In this route, we provide an additional map that adds the extension digit <code>9</code> to the CDPN (<code>->9</code>) and routes it to the PBX again.


A caller that dials only 3 matching digits(e.g. 200), will stay forever(until he hangs up) in the relay route for the 4 digits. The gateway waits for following digits, which will never come.
Here are the individual configuration steps:


Also changing the order of the routing table entries will not help:
* In your PBX, create a ''Gateway'' object without number and register a Relay-GWx (e.g. <code>GW1</code>) interface at it
PRIx CDPN:200 -> CDPN:2009 to RPx
* In your PBX, configure the newly created ''Gateway' object as ''Incomplete'' destination of your standard ''Trunk line'' object
PRIx CDPN:2001 -> CDPN:2001 to RPx
* In the ''Gateway/Routing'' table, create a route from your GWx (e.g. <code>GW1</code>) to <code>DISC</code> and use a re-routing cause code (e.g. 44) when disconnecting the call
* In the ''Gateway/Routing'' table, add an additional map to the original ''trunk-to-PBX'' route that adds the extension digit and routes the call to the PBX again


Now the first route will also match if the caller wants to dial 2001, sending the call to the PBX with the wrong CDPN.
==== Alternative without disconnecting the Call ====
An alternative would be to send back looped back call directly to the PBX (after adding the extension digit).  This would work, however it has the disadvantage that the PBX CDRs would show each call twice (the original and the looped call).  With the solution suggested, the CDRs would show a disconnected call with the wrong (i.e. old) CDPN followed by a another call to the correct (i.e. new) CDPN.


===Resolution===
==== SIP Trunks ====
We will route calls from the PSTN to the PBX and try to find a matching extension. Overlapping 3 digit extensions, will trigger an 'Incomplete' - Timeout at the TrunkLine Object, which we will use to reroute only this calls back to the Relay for CDPN-manipulation. After adjusting the CDPN, this calls also need to be rerouted back to the PBX.
If a provider doesn't use Overlap-Dialling (most SIP-providers don't support it), you can use the simplified solution explained in the ''Problem Details'' section. Using our example, you can just have a map matching the 4 digit extensions (<code>....-></code>) and following that one for the 3 digit extensions (<code>...->9</code>).


Here are the individual configuration steps:
A 3-digit caller will not hang in the first map forever, because it is signalled to the gateway that the sending of the number is complete. It will therefore skip the 4-digit map, and try to apply the following maps.


* In your PBX, create a Gateway object without number and register a Relay-GWx(e.g. GW1) interface at it.
Nevertheless the previously described solution for ISDN-trunks will work also for such SIP-trunks, it is just more complicated to configure.
* In your PBX, configure the newly created Gateway object as ''Incomplete'' destination of your Trunkline object(used to register your ISDN interfaces)
* In the Gateway Routing-Table, make a route from GWx(e.g. GW1) to DISC and use a rerouting cause code(e.g. 44) when disconnecting the call
* In the Gateway Routing-Table, add an additional route below routing from PRIx(or BRIx) to RPx(or RBx) with the mapping from 3 to 4digit extensions.


== Related Articles ==
* [[Reference:Rerouting_Causes]]
[[Category:Howto|{{PAGENAME}}]]
[[Category:Howto|{{PAGENAME}}]]

Latest revision as of 16:38, 1 April 2016

Applies To

This information applies to

  • all gateways, Firmware V8 or later

More Information

When customers migrate their PBX numbering plan from shorter to longer extension (say, from 3 to 4-digit extensions), there is a need to map the old shorter extension to the corresponding new longer extensions. As the PBX does not allow to create objects with overlapping Number properties (e.g. two objects with Numbers 200 and 2009, this must be done in the gateway layer of the corresponding trunk access.

In this article we will assume that the PBX uses 4 digit extension, while 3-digit extension should also be dial-able from the PSTN. However any other digit-length combination can be used.

Problem Details

Since you cannot have overlapping numbers in the PBX, you will have to use different numbers (e.g. instead of 200 we use 2009) in the PBX and map the numbers correctly using the Relay (200 -> 2009).

Unfortunately, the obvious idea to have an incoming map matching the 4 digit extensions (....->) and following that one for the 3 digit extensions (...->9), will not work. This is because a 3-digit caller will hang in the first map forever, as the gateway waits for following digits, which will never come.

Also, swapping the order of the routing table entries will not help either, as then the first map will also match if the caller wants to dial 2001, sending the call to the PBX with the wrong CDPN.

Resolution

We will route calls from the PSTN to the PBX and try to find a matching extension. Short 3 digit extensions, will trigger an 'Incomplete' - Timeout at the Trunk Line object, which we will use to reroute such calls back to the Gateway level. Here we arrange for the call to be disconnected with a so-called rerouting cause (see Reference:Rerouting_Causes). Because of this, the disconnected call will fall back to the PBX and from there back to the Gateway level (that is, to the first route sending the call from your trunk interface to the PBX). In this route, we provide an additional map that adds the extension digit 9 to the CDPN (->9) and routes it to the PBX again.

Here are the individual configuration steps:

  • In your PBX, create a Gateway object without number and register a Relay-GWx (e.g. GW1) interface at it
  • In your PBX, configure the newly created Gateway' object as Incomplete destination of your standard Trunk line object
  • In the Gateway/Routing table, create a route from your GWx (e.g. GW1) to DISC and use a re-routing cause code (e.g. 44) when disconnecting the call
  • In the Gateway/Routing table, add an additional map to the original trunk-to-PBX route that adds the extension digit and routes the call to the PBX again

Alternative without disconnecting the Call

An alternative would be to send back looped back call directly to the PBX (after adding the extension digit). This would work, however it has the disadvantage that the PBX CDRs would show each call twice (the original and the looped call). With the solution suggested, the CDRs would show a disconnected call with the wrong (i.e. old) CDPN followed by a another call to the correct (i.e. new) CDPN.

SIP Trunks

If a provider doesn't use Overlap-Dialling (most SIP-providers don't support it), you can use the simplified solution explained in the Problem Details section. Using our example, you can just have a map matching the 4 digit extensions (....->) and following that one for the 3 digit extensions (...->9).

A 3-digit caller will not hang in the first map forever, because it is signalled to the gateway that the sending of the number is complete. It will therefore skip the 4-digit map, and try to apply the following maps.

Nevertheless the previously described solution for ISDN-trunks will work also for such SIP-trunks, it is just more complicated to configure.

Related Articles