[Freeswitch-users] codec error
Steven Ayre
steveayre at gmail.com
Fri Jan 7 11:15:56 MSK 2011
show codecs
type,name,ikey
codec,AMR,mod_amr
codec,G.711 alaw,CORE_PCM_MODULE
codec,G.711 ulaw,CORE_PCM_MODULE
codec,G.723.1 6.3k,mod_g723_1
codec,G.729,mod_g729
codec,H.261 Video (passthru),mod_h26x
codec,H.263 Video (passthru),mod_h26x
codec,H.263+ Video (passthru),mod_h26x
codec,H.263++ Video (passthru),mod_h26x
codec,H.264 Video (passthru),mod_h26x
codec,PROXY PASS-THROUGH,CORE_PCM_MODULE
codec,PROXY VIDEO PASS-THROUGH,CORE_PCM_MODULE
codec,Polycom(R) G722.1/G722.1C,mod_siren
codec,RAW Signed Linear (16 bit),CORE_PCM_MODULE
codec,Speex,mod_speex
codec,iLBC,mod_ilbc
You have no module loaded that gives G722. Add mod_spandsp to modules.conf.xml
<X-PRE-PROCESS cmd="set"
data="global_codec_prefs=G7221 at 32000h,G7221 at 16000h,G7222,PCMU,PCMA,G729"/>
<X-PRE-PROCESS cmd="set"
data="outbound_codec_prefs=G722,G7222,G7221 at 32000h,G7221 at 16000h,PCMU,PCMA,G729"/>
That sets a variable. The actual definition of which codecs to use is
on the sip profile, which could use the variable that's set above, or
specify its own list. That should be fine as long as the profile uses
the variable, but they'll only be used if the codec is loaded - see
above.
-Steve
On 7 January 2011 06:58, Sam <u2nsam at gmail.com> wrote:
> in show codec i see ;
>
> show codecs
> type,name,ikey
> codec,AMR,mod_amr
> codec,G.711 alaw,CORE_PCM_MODULE
> codec,G.711 ulaw,CORE_PCM_MODULE
> codec,G.723.1 6.3k,mod_g723_1
> codec,G.729,mod_g729
> codec,H.261 Video (passthru),mod_h26x
> codec,H.263 Video (passthru),mod_h26x
> codec,H.263+ Video (passthru),mod_h26x
> codec,H.263++ Video (passthru),mod_h26x
> codec,H.264 Video (passthru),mod_h26x
> codec,PROXY PASS-THROUGH,CORE_PCM_MODULE
> codec,PROXY VIDEO PASS-THROUGH,CORE_PCM_MODULE
> codec,Polycom(R) G722.1/G722.1C,mod_siren
> codec,RAW Signed Linear (16 bit),CORE_PCM_MODULE
> codec,Speex,mod_speex
> codec,iLBC,mod_ilbc
>
> i have this in vars.xml
>
> <X-PRE-PROCESS cmd="set"
> data="global_codec_prefs=G7221 at 32000h,G7221 at 16000h,G7222,PCMU,PCMA,G729"/>
> <X-PRE-PROCESS cmd="set"
> data="outbound_codec_prefs=G722,G7222,G7221 at 32000h,G7221 at 16000h,PCMU,PCMA,G729"/>
>
>
>
> Regds
> Sam
>
>
>
> On Fri, Jan 7, 2011 at 12:07 PM, Sam <u2nsam at gmail.com> wrote:
>>
>> Where does it compare these codecs,
>>
>> 2011-01-07 12:05:12.420182 [DEBUG] sofia_glue.c:4401 Audio Codec Compare
>> [G722:9:8000:0:64000]/[G7221:115:32000:20:48000]
>> 2011-01-07 12:05:12.420182 [DEBUG] sofia_glue.c:4401 Audio Codec Compare
>> [G722:9:8000:0:64000]/[G7221:107:16000:20:32000]
>> 2011-01-07 12:05:12.420182 [DEBUG] sofia_glue.c:4401 Audio Codec Compare
>> [G722:9:8000:0:64000]/[PCMU:0:8000:20:64000]
>> 2011-01-07 12:05:12.420182 [DEBUG] sofia_glue.c:4401 Audio Codec Compare
>> [G722:9:8000:0:64000]/[PCMA:8:8000:20:64000]
>> 2011-01-07 12:05:12.420182 [DEBUG] sofia_glue.c:4401 Audio Codec Compare
>> [G722:9:8000:0:64000]/[G729:18:8000:20:8000]
>> 2011-01-07 12:05:12.420182 [DEBUG] sofia_glue.c:4401 Audio Codec Compare
>> [telephone-event:127:8000:0:0]/[G7221:115:32000:20:48000]
>> 2011-01-07 12:05:12.420182 [DEBUG] sofia_glue.c:4401 Audio Codec Compare
>> [telephone-event:127:8000:0:0]/[G7221:107:16000:20:32000]
>> 2011-01-07 12:05:12.420182 [DEBUG] sofia_glue.c:4401 Audio Codec Compare
>> [telephone-event:127:8000:0:0]/[PCMU:0:8000:20:64000]
>> 2011-01-07 12:05:12.420182 [DEBUG] sofia_glue.c:4401 Audio Codec Compare
>> [telephone-event:127:8000:0:0]/[PCMA:8:8000:20:64000]
>> 2011-01-07 12:05:12.420182 [DEBUG] sofia_glue.c:4401 Audio Codec Compare
>> [telephone-event:127:8000:0:0]/[G729:18:8000:20:8000]
>>
>>
>> I need to add g722
>>
>> Regds
>> Sam
>>
>> On Thu, Jan 6, 2011 at 4:34 PM, Steven Ayre <steveayre at gmail.com> wrote:
>>>
>>> This sip profile parameter would allow the G729 call to work,
>>> providing G729 is enabled on the Cisco:
>>> <param name="disable-transcoding" value="true"/>
>>>
>>> This will mean the INVITE sent to the Cisco on the bleg only includes
>>> the codec from the aleg. The aleg is already using G729, so the Cisco
>>> will only be offered G729. It is then forced to either accept G729 or
>>> fail the call with Incompatible Destination.
>>>
>>> -Steve
>>>
>>>
>>> On 6 January 2011 10:59, Steven Ayre <steveayre at gmail.com> wrote:
>>> > G722.2
>>> > ======
>>> >
>>> > This codec is not enabled on your server.
>>> >
>>> > 2011-01-06 15:30:43.041645 [DEBUG] sofia_glue.c:4403 Audio Codec
>>> > Compare [g7222:110:16000:110:0]/[G7221:115:32000:20:48000]
>>> > 2011-01-06 15:30:43.041645 [DEBUG] sofia_glue.c:4403 Audio Codec
>>> > Compare [g7222:110:16000:110:0]/[G7221:107:16000:20:32000]
>>> > 2011-01-06 15:30:43.041645 [DEBUG] sofia_glue.c:4403 Audio Codec
>>> > Compare [g7222:110:16000:110:0]/[PCMU:0:8000:20:64000]
>>> > 2011-01-06 15:30:43.041645 [DEBUG] sofia_glue.c:4403 Audio Codec
>>> > Compare [g7222:110:16000:110:0]/[PCMA:8:8000:20:64000]
>>> > 2011-01-06 15:30:43.041645 [DEBUG] sofia_glue.c:4403 Audio Codec
>>> > Compare [g7222:110:16000:110:0]/[G729:18:8000:20:8000]
>>> >
>>> > You are calling with G722.2.
>>> >
>>> > G722.1 is enabled, but G722.2 is not.
>>> >
>>> > G729
>>> > ====
>>> >
>>> > It rings because Cisco returns 180 Ringing with no SDP. At that time
>>> > no codec has been selected. Anything you hear will be generated by
>>> > your SIP client.
>>> >
>>> > The codec is selected in the 200 OK w/SDP. That is the time the codec
>>> > is picked.
>>> >
>>> > FreeSWITCH offers G729 to Cisco in the INVITE, plus several other
>>> > codecs:
>>> > m=audio 24636 RTP/AVP 18 98 99 0 8 101 13
>>> > The Cisco only responds with PCMU:
>>> > m=audio 31600 RTP/AVP 0 101
>>> > ( 18=G729 0=PCMU 8=PCMA 98/99=G722.1 )
>>> >
>>> > Either your FS config has changed so that is offering more codecs than
>>> > before, or the Cisco's config has changed to prefer G711 over G729.
>>> >
>>> > -Steve
>>> >
>>> >
>>> > On 6 January 2011 10:45, Sam <u2nsam at gmail.com> wrote:
>>> >> http://pastebin.freeswitch.org/14934
>>> >> http://pastebin.freeswitch.org/14935
>>> >>
>>> >> These are the paste bins where calls with g722 and G729 call fails but
>>> >> g729
>>> >> calls rings and gets disconnected.
>>> >> In past it was working with both the codec on the same server as no
>>> >> there is
>>> >> no config change.
>>> >>
>>> >>
>>> >> Regds
>>> >> Sam
>>> >>
>>> >>
>>> >>
>>> >> On Thu, Jan 6, 2011 at 4:00 PM, Steven Ayre <steveayre at gmail.com>
>>> >> wrote:
>>> >>>
>>> >>> G7222 call fails with incompatible destination because it's not
>>> >>> enabled on the server.
>>> >>>
>>> >>> G729 call starts a bridge to user/7013 at 192.168.2.190. They only offer
>>> >>> G711 ulaw. That means it's a G729 -> G711 call requiring transcoding.
>>> >>> There is no way that can work using mod_g729.
>>> >>>
>>> >>> If you believe that that user has G729 enabled, repeat the test with
>>> >>> sip trace enabled.
>>> >>> 'sofia global siptrace on'
>>> >>>
>>> >>> That'll let you see the INVITE w/SDP sent to the user. If G729 isn't
>>> >>> in the outgoing SDP it's a config problem on FreeSWITCH. If G729 is
>>> >>> in
>>> >>> the SDP and the user is only responding with G711 then it's a problem
>>> >>> on the Cisco endpoint.
>>> >>>
>>> >>> -Steve
>>> >>>
>>> >>>
>>> >>>
>>> >>> On 6 January 2011 10:10, Sam <u2nsam at gmail.com> wrote:
>>> >>> > Hi,
>>> >>> >
>>> >>> > This was working earlier and the config file have not changed ,
>>> >>> > only
>>> >>> > upgraded to latest git.
>>> >>> > have attached the file codec.txt .
>>> >>> >
>>> >>> >
>>> >>> >
>>> >>> > Regards
>>> >>> > Sam
>>> >>> >
>>> >>> >
>>> >>> >
>>> >>> > On Thu, Jan 6, 2011 at 3:20 PM, Steven Ayre <steveayre at gmail.com>
>>> >>> > wrote:
>>> >>> >>
>>> >>> >> Some more information please...
>>> >>> >>
>>> >>> >> G729 has patents that mean it can't be used unlicensed. FreeSWITCH
>>> >>> >> either has mod_com_g729 for a full featured licensed version, or
>>> >>> >> mod_g729 which operates in passthrough mode for G729-G729 calls
>>> >>> >> (it
>>> >>> >> needs no license since for these calls there is no
>>> >>> >> encoding/decoding
>>> >>> >> step, the already encoded data is just passed straight through).
>>> >>> >> You
>>> >>> >> will never have had mod_g729 working in the past for a transcoding
>>> >>> >> call, so that won't have changed.
>>> >>> >>
>>> >>> >> I would say that it's either:
>>> >>> >> - Your config files have changed
>>> >>> >> - The endpoints are offering different codecs from before
>>> >>> >> - Something changed in git about the codec negotiation
>>> >>> >>
>>> >>> >> Can you pastebin a debug level log of the calls, and enable
>>> >>> >> siptrace?
>>> >>> >> Those will show what codecs are being offered, selected and show
>>> >>> >> the
>>> >>> >> codec negotiation. It'd also be useful to know what your sip
>>> >>> >> profile
>>> >>> >> config files look like since there are several options that adjust
>>> >>> >> how
>>> >>> >> the negotiation is done.
>>> >>> >>
>>> >>> >> -Steve
>>> >>> >>
>>> >>> >>
>>> >>> >>
>>> >>> >> On 6 January 2011 09:43, Sam <u2nsam at gmail.com> wrote:
>>> >>> >> > I am getting the error after installing latest git from
>>> >>> >> > freeswitch,
>>> >>> >> > where as
>>> >>> >> > it was working from old git
>>> >>> >> >
>>> >>> >> >
>>> >>> >> > 2011-01-06 15:10:19.113781 [ERR] mod_g729.c:102 This codec is
>>> >>> >> > only
>>> >>> >> > usable in
>>> >>> >> > passthrough mode!
>>> >>> >> > 2011-01-06 15:10:19.113781 [ERR] switch_core_io.c:1042 Codec
>>> >>> >> > G.729
>>> >>> >> > encoder
>>> >>> >> > error!
>>> >>> >> >
>>> >>> >> >
>>> >>> >> > Regards
>>> >>> >> > Sam
>>> >>> >> >
>>> >>> >> > _______________________________________________
>>> >>> >> > FreeSWITCH-users mailing list
>>> >>> >> > FreeSWITCH-users at lists.freeswitch.org
>>> >>> >> > http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> >>> >> >
>>> >>> >> >
>>> >>> >> > UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> >>> >> > http://www.freeswitch.org
>>> >>> >> >
>>> >>> >> >
>>> >>> >>
>>> >>> >> _______________________________________________
>>> >>> >> FreeSWITCH-users mailing list
>>> >>> >> FreeSWITCH-users at lists.freeswitch.org
>>> >>> >> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> >>> >>
>>> >>> >>
>>> >>> >> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> >>> >> http://www.freeswitch.org
>>> >>> >
>>> >>> >
>>> >>> > _______________________________________________
>>> >>> > FreeSWITCH-users mailing list
>>> >>> > FreeSWITCH-users at lists.freeswitch.org
>>> >>> > http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> >>> >
>>> >>> > UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> >>> > http://www.freeswitch.org
>>> >>> >
>>> >>> >
>>> >>>
>>> >>> _______________________________________________
>>> >>> FreeSWITCH-users mailing list
>>> >>> FreeSWITCH-users at lists.freeswitch.org
>>> >>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> >>>
>>> >>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> >>> http://www.freeswitch.org
>>> >>
>>> >>
>>> >> _______________________________________________
>>> >> FreeSWITCH-users mailing list
>>> >> FreeSWITCH-users at lists.freeswitch.org
>>> >> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> >>
>>> >> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> >> http://www.freeswitch.org
>>> >>
>>> >>
>>> >
>>>
>>> _______________________________________________
>>> FreeSWITCH-users mailing list
>>> FreeSWITCH-users at lists.freeswitch.org
>>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> http://www.freeswitch.org
>>
>
>
> _______________________________________________
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
>
More information about the FreeSWITCH-users
mailing list