[SR-Users] Redirection buffer length exceed
Daniel-Constantin Mierla
miconda at gmail.com
Thu Nov 6 10:28:16 CET 2014
Hello,
On 06/11/14 09:38, Dan Christian Bogos wrote:
> Hey Guys,
>
> We are facing quite often this error:
>
> /usr/sbin/kamailio[16985]: ERROR:
> <core> [dset.c:435]: print_dset(): ERROR: redirection buffeROR:
> redirection buffer length exceed
>
> When the error is generated, there will be a missing contact in the
> redirects (not to mention that Kamailio will crash in uac_redirect for
> versions before 4.2.0).
>
> Can anyone explain the nature of this buffer and whether is affected
> by a single contact or all the contacts together building the final
> redirect? How can we control what's in that buffer from the script?
>
> This is our script part building the redirects, out of location data:
> """
> if(!reg_fetch_contacts("location", "$ru", "called")) {
> send_reply("404", "Not Found");
> exit;
> }
> if $(ulc(called=>count)) == 0 { # No contacts for this user online
> sl_send_reply("404", "Not found");
> exit;
> }
> $var(i) = 0;
> while($var(i) < $(ulc(called=>count))) {
> $var(pathUri) =
> $(ulc(called=>path)[$var(i)]{s.strip,1}{s.striptail,1}); #Strip <> so
> we can apply real uri transformations
> $var(newRURI) = $(ulc(called=>addr)[$var(i)]) +
> ";ipbxep=" + $(var(pathUri){uri.host});
> if $var(i) == 0 {
> $ru = $var(newRURI);
> } else {
> append_branch($var(newRURI));
> }
> $var(i) = $var(i) + 1;
> }
> """
>
> Thanks in advance for any kind of tip!
looks like the overall buffer for contacts in redirect is 512 in size,
perhaps same value from early beginnings. MAX_REDIRECTION_LEN in
config.h needs to be changed to larger value -- should 1024 be enough?
Cheers,
Daniel
--
Daniel-Constantin Mierla
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio Advanced Training, Nov 24-27, Berlin - http://www.asipto.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20141106/c1f7cddc/attachment.html>
More information about the sr-users
mailing list