[Freeswitch-users] Codec list truncation?

Lawrence Conroy lconroy at insensate.co.uk
Fri Mar 21 18:30:23 MSK 2014


Hi there,
 to be picky on terminology: UDP deals in packets. The underlying IP network deals in datagrams.
NB: What follows is IPv4 stuff — if you’re using IPv6, fragmentation and reassembly isn’t done (or at least, not this way).
Your initial mail suggested you’re using net 10 addresses (hence IPv4), so this should be all good:

Normally, one UDP packet fits into one IP datagram. If it doesn’t, the sending host will split this into into a sequence of datagrams (also known as fragments), each of which will be sent separately across the network. The receiving host (i.e., the one with the IP address to which the UDP packet is sent) is responsible for sticking these fragments together to make one UDP packet, and for passing this to the listening application.

I’d be willing to suspect that the full SIP/SDP message is passed in ->a<- UDP packet to the network stack at the sending host, and that stack will fragment it into several datagrams automatically if it’s too big to fit in one. fS doesn’t deal with datagrams (it’s an application using UDP packets).
The receiving host network stack will pick up the datagram (or set of fragments) from the network, will stitch them together as needed, and the completed UDP packet will be passed up the stack, again automatically. The receiving fS/SIP server|client will receive that UDP packet and act on it.

     - BUT -

Many routers/firewalls are severely brain damaged and drop subsequent fragments. They simply aren’t passed on to the destination host to reassemble. [I get this with DNS packets as well, so it’s not just SIP that gets b*gg*red].
I believe some folks (unwisely) set their host network stack to disable packet fragmentation and reassembly (which will mean the receiving host doesn’t even try to re-build packets — it just goes with the first [non-zero offset] datagram it receives).

Hence the requests from others:
Looking at a PCAP/Wireshark capture of the traffic “over the wire”, how big are the datagrams, is there more than one fragment (i.e., a datagram with a non-zero data offset), and does that “fit” with what you’re seeing at the receiving end?

Also a question from me: Are there any intermediaries (firewall/NAT/routers/[VPN|V4-in-v6] tunnels) between the SIP source and destination?

all the best,
  Lawrence

On 21 Mar 2014, at 14:41, Pete Ashdown <pashdown at xmission.com> wrote:
> On 03/21/2014 03:32 AM, Keith Laaks wrote:
>> Hi,
>> 
>> Are you perhaps hitting the MTU limit?
>> 
> 
> Are SIP transmissions limited to a single packet confined by MTU?  Why
> not just continue the list in the next packet?
> 
> 
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
> 
> 
> 
> 
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://wiki.freeswitch.org
> http://www.cluecon.com
> 
> 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




Join us at ClueCon 2013 Aug 6-8, 2013
More information about the FreeSWITCH-users mailing list