We run asterisk to handle incoming DIDs and we have observed
inefficient Codec Translation.
Here is the scenario
[DID Vendor] ---------------------------> [Asterisk ]
------------------------> External GW [G729]
|
|-------------------> External GW [iLBC]
Our DID vendor and asterisk box supports both ilbc & g729. However,
our external gateway termination supports either ilbc or g729 (and not
both) and depending on users location, we terminate it on either
gateway.
Since DID and asterisk box supports both the codecs, we assumed that
asterisk will appropriately select codecs depending on where we
terminate the call so that no codec translation happens. However, this
seems to be an incorrect assumption and we see that different codecs
get selected on two legs which leads to quality drop and extra CPU
cycles.
May be we are doing something wrong. Pls suggest what we are doing
wrong. Below is asterisk configuration.
[did]
type=friend
host=xxx
canreinvite=yes
disallow=all
allow=g729
allow=ilbc
[gw1]
type=friend
host=xxx
canreinvite=yes
disallow=all
allow=g729
[gw2]
type=friend
host=xxx
canreinvite=yes
disallow=all
allow=ilbc
Thanks
Jim
Requesting help. Thaks On Tue, Aug 19, 2008 at 4:40 PM, Jim Boykin <boykinjim at gmail.com> wrote:> We run asterisk to handle incoming DIDs and we have observed > inefficient Codec Translation. > > Here is the scenario > > [DID Vendor] ---------------------------> [Asterisk ] > ------------------------> External GW [G729] > | > > |-------------------> External GW [iLBC] > > Our DID vendor and asterisk box supports both ilbc & g729. However, > our external gateway termination supports either ilbc or g729 (and not > both) and depending on users location, we terminate it on either > gateway. > > Since DID and asterisk box supports both the codecs, we assumed that > asterisk will appropriately select codecs depending on where we > terminate the call so that no codec translation happens. However, this > seems to be an incorrect assumption and we see that different codecs > get selected on two legs which leads to quality drop and extra CPU > cycles. > > May be we are doing something wrong. Pls suggest what we are doing > wrong. Below is asterisk configuration. > > [did] > type=friend > host=xxx > canreinvite=yes > disallow=all > allow=g729 > allow=ilbc > > [gw1] > type=friend > host=xxx > canreinvite=yes > disallow=all > allow=g729 > > [gw2] > type=friend > host=xxx > canreinvite=yes > disallow=all > allow=ilbc > > Thanks > Jim >
On Tue, Aug 19, 2008 at 7:10 AM, Jim Boykin <boykinjim at gmail.com> wrote:> We run asterisk to handle incoming DIDs and we have observed > inefficient Codec Translation. > > Here is the scenario > > [DID Vendor] ---------------------------> [Asterisk ] > ------------------------> External GW [G729] > | > > |-------------------> External GW [iLBC] > > Our DID vendor and asterisk box supports both ilbc & g729. However, > our external gateway termination supports either ilbc or g729 (and not > both) and depending on users location, we terminate it on either > gateway. > > Since DID and asterisk box supports both the codecs, we assumed that > asterisk will appropriately select codecs depending on where we > terminate the call so that no codec translation happens. However, this > seems to be an incorrect assumption and we see that different codecs > get selected on two legs which leads to quality drop and extra CPU > cycles. > > May be we are doing something wrong. Pls suggest what we are doing > wrong. Below is asterisk configuration. > > [did] > type=friend > host=xxx > canreinvite=yes > disallow=all > allow=g729 > allow=ilbc > > [gw1] > type=friend > host=xxx > canreinvite=yes > disallow=all > allow=g729 > > [gw2] > type=friend > host=xxx > canreinvite=yes > disallow=all > allow=ilbc > > Thanks > Jim >Why don't you allow=g729 only on all entries. Maybe I have misread your email but I interpret what you wrote to mean that all endpoints support g729
On Tue, Aug 19, 2008 at 7:10 AM, Jim Boykin <boykinjim at gmail.com> wrote:> We run asterisk to handle incoming DIDs and we have observed > inefficient Codec Translation. > > Here is the scenario > > [DID Vendor] ---------------------------> [Asterisk ] > ------------------------> External GW [G729] > | > > |-------------------> External GW [iLBC] > > Our DID vendor and asterisk box supports both ilbc & g729. However, > our external gateway termination supports either ilbc or g729 (and not > both) and depending on users location, we terminate it on either > gateway. > > Since DID and asterisk box supports both the codecs, we assumed that > asterisk will appropriately select codecs depending on where we > terminate the call so that no codec translation happens. However, this > seems to be an incorrect assumption and we see that different codecs > get selected on two legs which leads to quality drop and extra CPU > cycles. > > May be we are doing something wrong. Pls suggest what we are doing > wrong. Below is asterisk configuration. > > [did] > type=friend > host=xxx > canreinvite=yes > disallow=all > allow=g729 > allow=ilbc > > [gw1] > type=friend > host=xxx > canreinvite=yes > disallow=all > allow=g729 > > [gw2] > type=friend > host=xxx > canreinvite=yes > disallow=all > allow=ilbc > > Thanks > Jim >To be more clear, when a call comes in on [did] the codec should match on the order that they are listed and supported, so you should always get g729 and transcode to ilbc on gw2. Asterisk handles one leg at a time, so it does not look ahead to see what the second leg of the call will be using for it's codec. Thanks, Steve T