[Serusers] UDP fragmentation

Andrei Pelinescu-Onciul pelinescu-onciul at fokus.fraunhofer.de
Sun Jan 4 14:55:24 CET 2004


On Jan 03, 2004 at 23:43, Thilo Salmon <salmon at netzquadrat.de> wrote:
> On Fri, 2004-01-02 at 18:42, Nils Ohlmeier wrote:
> [INVITE messages to large to avoid fragmented UDP packets]
> > You can remove header fields with the remove_hf() function from the textops 
> > module. You should verify that you do not remove required header fields, but 
> > basicly it should be possible to do it that way. Allthough i think this not a 
> > very good solution because you will never know to which size the request will 
> > grow and if you will be able to strip it down under 1500.
> 
> Thanks a lot for pointing this out. I was looking for this function. It
> has not yet been documented, I believe.  Do you happen to know, if there
> is a similar function to determine the size of the current message? That
> would come in handy, since you could refrain from stripping information
> unless the message was too large. Or even strip a little more, if you
> knew for certain that a call could not be set up unless you avoid
> fragmentation.

 if (msg:len >=  1472 ){  /* 1472 data + 8 (udp header) + 20 (standard ip
 header) = 1500 */
 /* .....*/
 }
> 
> > I think the better choice is to switch to TCP to eliminate the MTU
> problem. 
> > Either directly at the starting UA, or you can also switch the transport at 
> > SER with forcing the transport for forwarding to TCP.
> 
> I guess I have to read up on SIP over TCP. With regards to NAT it sounds
> a little like trading lemons, since by the sounds of it you are
> introducing a whole new set of problems. 

AFAIK nobody tried this so far, but it should work :-)
> 
> That comes hard, since I was just too happy I had solved all my SIP
> through NAT issues...

If you can, stick to udp.

Andrei




More information about the sr-users mailing list