Hi, I ahve been using the RTP packetization patch for a while, and its going great. I have a few questions: I always get this message: 2006-08-31 22:11:22 WARNING[1278]: frame.c:1072 ast_codec_pref_getsize: Framing not set for codec alaw, using default 20 even though I set in sip.conf [general] context=default ; Default context for incoming calls disallow=all ; First disallow all codecs allow=ulaw:20 allow=alaw:20 allow=g729:80 autoframing=yes am I doing something wrong? Also, I am not sure if this is a bug. If in sip.conf, if I set [yusuf] username=yusuf secret=yusuf type=friend callerid=1002 nat=yes canreinvite=no allow=all host=dynamic context=sip then when asterisk calls, it says I have not set Framing (like above msg), then asterisk just dies. If I chane the line allow=all to allow=alaw:20 then its fine, and asterisk does not die. Dont know if this is a bug, so I wont post debug/full messages now. thanks, yusuf -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.
Dan Austin
2006-Aug-31 14:51 UTC
[asterisk-users] 0005162: RTP Packetization : Few questions
> I ahve been using the RTP packetization patch for a while, and > its going great. I have a few questions:That is excellent.> I always get this message: > 2006-08-31 22:11:22 WARNING[1278]: frame.c:1072 > ast_codec_pref_getsize: Framing not set for codec alaw, using > default 20Not so excellent.> even though I set in sip.conf> [general] > context=default ; Default context for incoming calls > disallow=all ; First disallow all codecs > allow=ulaw:20 > allow=alaw:20 > allow=g729:80 > autoframing=yes> am I doing something wrong?That looks fine. Does it work with: allow:ulaw:20,alaw:20,g729:80 ?> Also, I am not sure if this is a bug. > If in sip.conf, if I set> [yusuf] > username=yusuf > secret=yusuf > type=friend > callerid=1002 > nat=yes > canreinvite=no > allow=all > host=dynamic > context=sipBUG! Which version of the patch and what SVN version? I suspect it has to do with one or more of the codecs that we could not find framing/packetization details about. Is alaw the codec used in the call that causes the crash?> then when asterisk calls, it says I have not set Framing (like abovemsg),> then asterisk just dies.> If I chane the line > allow=all to allow=alaw:20> then its fine, and asterisk does not die.> Dont know if this is a bug, so I wont post debug/full messages now.Dan
Dan Austin
2006-Sep-07 10:24 UTC
[asterisk-users] 0005162: RTP Packetization : Few questions
> As far as the above is concerned I have the following:> I am using Asterisk 1.2.10, patched with this patch for 1.2.10. > I have 2 * boxes. They call each other over SIP, and I have in > sip.conf on both boxes> autoframing=yes > disallow=all > allow=g729:80> When A calls B, it sets ptime:80.> On B I see this: > We're at 192.168.0.64 port 11004 > Adding codec 0x100 (g729) to SDP > Sep 7 18:16:16 WARNING[5529]: frame.c:1072 ast_codec_pref_getsize: > Framing not set for codec g729, using default 20 and ptime:20I'll have a look at the 1.2.10 patch> So B is setting packetization to 20, when it should be 80, and is not > respecting autoframing.Another developer wrote the autoframing feature, and I have not used it, but I'll look to see if there is an obvious reason why it does not find or honor the ptime. Can you capture the SIP INVITE dialog on box B so I can see the SDP offer, and look to see if the ptime element is present and set properly?> I have tried this with reinvites=yes and no, and autoframing=yes and > no, still the same.Can you try with autoframing=no and force 80ms on both sides?>>>Also, I am not sure if this is a bug. >>>If in sip.conf, if I set >> >> >>>[yusuf] >>>username=yusuf >>>secret=yusuf >>>type=friend >>>callerid=1002 >>>nat=yes >>>canreinvite=no >>>allow=all >>>host=dynamic >>>context=sip >> >> >> BUG! >> Which version of the patch and what SVN version? I suspect it has >> to do with one or more of the codecs that we could not find >> framing/packetization details about. Is alaw the codec used in the >> call that causes the crash? >> >> >>>then when asterisk calls, it says I have not set Framing (like above >> >> msg), >> >>>then asterisk just dies. >> >> >>>If I chane the line >>>allow=all to allow=alaw:20 >> >> >>>then its fine, and asterisk does not die. >> >> >>>Dont know if this is a bug, so I wont post debug/full messages now. >>
Dan Austin
2006-Sep-07 12:23 UTC
[asterisk-users] 0005162: RTP Packetization : Few questions
>>2006-08-31 22:11:22 WARNING[1278]: frame.c:1072 >>ast_codec_pref_getsize: Framing not set for codec alaw, using >>default 20 > > As far as the above is concerned I have the following:> I am using Asterisk 1.2.10, patched with this patch for 1.2.10. > I have 2 * boxes. They call each other over SIP, and I have in > sip.conf on both boxes> autoframing=yes > disallow=all > allow=g729:80> When A calls B, it sets ptime:80.> On B I see this: > We're at 192.168.0.64 port 11004 > Adding codec 0x100 (g729) to SDP > Sep 7 18:16:16 WARNING[5529]: frame.c:1072 ast_codec_pref_getsize: > Framing not set for codec g729, using default 20 and ptime:20> So B is setting packetization to 20, when it should be 80, and is > not respecting autoframing.> I have tried this with reinvites=yes and no, and autoframing=yes and > no, still the same.The autoframing patch forgot to remove an earlier check for 'ptime' in the SDP that would cause chan_sip to ignore the ptime value. I am working on trunk, so the line numbers may not match up, but near line 4748 you will should find this block of code: } else if (!strncasecmp(a, "ptime:", (size_t) 6)) { if (debug) ast_verbose("Got unsupported a:ptime in SDP offer \n"); breakout = TRUE; Simply comment out the breakout = TRUE; line like this. } else if (!strncasecmp(a, "ptime:", (size_t) 6)) { if (debug) ast_verbose("Got unsupported a:ptime in SDP offer \n"); /* breakout = TRUE; */ That fixes up autoframing in my tests, if it works for you, I will prepare a proper patch. Dan
Dan Austin
2006-Sep-08 09:58 UTC
[asterisk-users] 0005162: RTP Packetization : Few questions
Is autoframing set to yes in the [general] section? A current limitation in the code is that a global autoframing will override a user/peer setting. Dan -----Original Message----- From: asterisk-users-bounces@lists.digium.com [mailto:asterisk-users-bounces@lists.digium.com] On Behalf Of yusuf Sent: Friday, September 08, 2006 2:26 AM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: Re: [asterisk-users] 0005162: RTP Packetization : Few questions Dan Austin wrote:>>>2006-08-31 22:11:22 WARNING[1278]: frame.c:1072 >>>ast_codec_pref_getsize: Framing not set for codec alaw, using >>>default 20 >> >>As far as the above is concerned I have the following: > > >>I am using Asterisk 1.2.10, patched with this patch for 1.2.10. >>I have 2 * boxes. They call each other over SIP, and I have in >>sip.conf on both boxes > > >>autoframing=yes >>disallow=all >>allow=g729:80 > > >>When A calls B, it sets ptime:80. > > >>On B I see this: >>We're at 192.168.0.64 port 11004 >>Adding codec 0x100 (g729) to SDP >>Sep 7 18:16:16 WARNING[5529]: frame.c:1072 ast_codec_pref_getsize: >>Framing not set for codec g729, using default 20 and ptime:20 > > >>So B is setting packetization to 20, when it should be 80, and is >>not respecting autoframing. > > >>I have tried this with reinvites=yes and no, and autoframing=yes and >>no, still the same. > > > The autoframing patch forgot to remove an earlier check for 'ptime' > in the SDP that would cause chan_sip to ignore the ptime value. > > I am working on trunk, so the line numbers may not match up, but > near line 4748 you will should find this block of code: > > } else if (!strncasecmp(a, "ptime:", (size_t) 6)) { > if (debug) > ast_verbose("Got unsupported > a:ptime in SDP offer \n"); > breakout = TRUE; > > Simply comment out the breakout = TRUE; line like this. > > } else if (!strncasecmp(a, "ptime:", (size_t) 6)) { > if (debug) > ast_verbose("Got unsupported > a:ptime in SDP offer \n"); > /* breakout = TRUE; */ > > That fixes up autoframing in my tests, if it works for you, I will > prepare a proper patch. >Hi, I will try this. But even with autoframing=no, B still sets ptime:20. on B in sip.conf [sipacket] username=sipacket secret=sipacket type=friend host=dynamic context=default disallow=all allow=g729:60 ;autoframing=yes ;canreinvite=no -- thanks, yusuf -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. _______________________________________________ --Bandwidth and Colocation provided by Easynews.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users