G722 Local - G711 External but long delay

Hi there,
I have a running FreePBX Distro on a Vsphere Cluster. 2x Xeon 2620v3 16GB DDR3.

I have some problems with audio delay.
My SIP Provider uses G.711
I use G.722 for local calls.

When i call out with G.711 Codec everything is working find.
When i call out with G.722, Asterisk is Transcoding to G.711. But i have a delay from 0.5 to 1 Second. This is much too long.

My Audio Layer Latency with Transcoding from G722 -> G711 is arround 580ms

Any Tips, solutions? I dont know how to solve this :frowning:

What are your trunk settings on the sip settings tab? Particularly the settings disallow and allow?

For example, I have in the PEER Details in the sip Settings tab…

disallow=all
allow=ulaw&g729

Also, check your Extension settings, Advanced page.
What is the Disallowed Codecs set to? (Mine = all)
What is the Allowed Codecs set to? (Mine = g722&ulaw&g729)

Thank you for your answer.

I have set disallow=all
allow=alaw (we use alaw in europe)

In my company inside i want to use g722.
So i set my extensions with disallow=all and allow=g722&alaw

But my phone calls out everywhere with g722.
Asterisk is transcoding the call to alaw.

core show transcode says my transcoding time from g722 to alaw is only 12ms.

As far as I know, those settings look good.

What kind of extensions? One type, or various?

Might seem like a silly question. But how do you know your transcoding times? You said you used core show transcode. However, are you actually experiencing delay on those extensions when dialing out?

FWIW: My g722 to ulaw is 15600, which is 15.6 milliseconds. Acer Aspire Netbook w/ AMD c series dual core c60 Processor 1GHz

core show translation

Translation times between formats (in microseconds) for one second of data
Source Format (Rows) Destination Format (Columns)

           ulaw  alaw   gsm  g726 g726aal2 adpcm  slin  slin  slin  slin  slin  slin  slin  slin  slin lpc10  ilbc  g722 testlaw
     ulaw     -  9150 15000 15000    15000 15000  9000 17000 17000 17000 17000 17000 17000 17000 17000 15000 15000 17250   15000
     alaw  9150     - 15000 15000    15000 15000  9000 17000 17000 17000 17000 17000 17000 17000 17000 15000 15000 17250   15000
      gsm 15000 15000     - 15000    15000 15000  9000 17000 17000 17000 17000 17000 17000 17000 17000 15000 15000 17250   15000
     g726 15000 15000 15000     -    15000 15000  9000 17000 17000 17000 17000 17000 17000 17000 17000 15000 15000 17250   15000
 g726aal2 15000 15000 15000 15000        - 15000  9000 17000 17000 17000 17000 17000 17000 17000 17000 15000 15000 17250   15000
    adpcm 15000 15000 15000 15000    15000     -  9000 17000 17000 17000 17000 17000 17000 17000 17000 15000 15000 17250   15000
     slin  6000  6000  6000  6000     6000  6000     -  8000  8000  8000  8000  8000  8000  8000  8000  6000  6000  8250    6000
     slin 14500 14500 14500 14500    14500 14500  8500     -  8000  8000  8000  8000  8000  8000  8000 14500 14500 14000   14500
     slin 14500 14500 14500 14500    14500 14500  8500  8500     -  8000  8000  8000  8000  8000  8000 14500 14500  6000   14500
     slin 14500 14500 14500 14500    14500 14500  8500  8500  8500     -  8000  8000  8000  8000  8000 14500 14500 14500   14500
     slin 14500 14500 14500 14500    14500 14500  8500  8500  8500  8500     -  8000  8000  8000  8000 14500 14500 14500   14500
     slin 14500 14500 14500 14500    14500 14500  8500  8500  8500  8500  8500     -  8000  8000  8000 14500 14500 14500   14500
     slin 14500 14500 14500 14500    14500 14500  8500  8500  8500  8500  8500  8500     -  8000  8000 14500 14500 14500   14500
     slin 14500 14500 14500 14500    14500 14500  8500  8500  8500  8500  8500  8500  8500     -  8000 14500 14500 14500   14500
     slin 14500 14500 14500 14500    14500 14500  8500  8500  8500  8500  8500  8500  8500  8500     - 14500 14500 14500   14500
    lpc10 15000 15000 15000 15000    15000 15000  9000 17000 17000 17000 17000 17000 17000 17000 17000     - 15000 17250   15000
     ilbc 15000 15000 15000 15000    15000 15000  9000 17000 17000 17000 17000 17000 17000 17000 17000 15000     - 17250   15000
     g722 15600 15600 15600 15600    15600 15600  9600 17500  9000 17000 17000 17000 17000 17000 17000 15600 15600     -   15600
  testlaw 15000 15000 15000 15000    15000 15000  9000 17000 17000 17000 17000 17000 17000 17000 17000 15000 15000 17250       -

Sorry i meaned core show translation not transcoding :smiley: 15ms

In X-Lite i can open a Device Test during a call. there i can see the codec which is used for the call and X-Lite also says i have an Audio Layer Latency 580ms with g722.

When i call with alaw, X-Lite says i have only 22ms Latency.