4/29/2016 - 4:04 PM


[Asterisk 13.6] Install opensource g729 codec

Try to find what kind of CPU you have using those commands

$ cat /proc/cpuinfo | grep 'sse' -m1
$ [sudo] dmidecode -t 4
$ lscpu

Download the codec binary corresponding to your CPU the MD5SUM file and compare the two

$ wget http://asterisk.hosting.lv/bin/{codec_g729-ast130-gcc4-glibc2.2-x86_64-core2-sse4.so,MD5SUM} -P /tmp/ && \
> md5sum -c MD5SUM 2>/dev/null | grep 'OK'

for example codec_g729-ast130-gcc4-glibc2.2-x86_64-core2-sse4.so

Delete old if any codec from asterisk modules directory, then copy the new one

$ [sudo] rm /usr/lib/asterisk/modules/codec_g72[39]*.so && \
> [sudo] cp /tmp/codec_g72[39]*.so /usr/lib/asterisk/modules/codec_g72[39].so

Restart Asterisk

$ [sudo] service asterisk restart

Check if the codec is correctly load

asterisk*CLI> core show translation recalc 10

Finally add the codec to your sip.conf or pjsip.conf globally or for a certain peer

source : http://asterisk.hosting.lv/