MPD and fragmentation

Alexander Motin mav at
Thu Jul 26 06:33:30 UTC 2007

Mihai Tanasescu wrote:
> First of all I'm getting icmp losses even if I use a test LAN to make a 
> tunnel to the local FBSD machine, but these don't seem to affect my 
> transfer rate when trying to get a large file via HTTP from the same 
> machine.

I have just merged small pptp windowing related patch to 6-STABLE, you 
can try it. Also you can try to disable windowing completely in mpd 
config, it is not really needed

> What bothers me most is that some sites (like,, 
> etc) don't seem to be loading.
> What I first thought about was the mss problem and so I discovered the 
> following:
> 22:54:36.633254 IP (tos 0x0, ttl  64, id 14254, offset 0, flags [DF], 
> proto: ICMP (1), length: 56) FBSD-IP > ICMP FBSD-IP 
> unreachable - need to frag (mtu 1336), length 36

It is widely known problem whith broken PMTUD at Microsoft. They filter 
that ICMP packets.

> In my config file I have:
> set iface mtu 1500
> set link mtu 1440

There is no need to specify both. Mpd will calculate iface mtu based on 
link mtu. iface mtu will be used only as upper limit.

> set iface enable tcpmssfix

Actually that should help, but it is strange to see "need to frag (mtu 
1336)" in you tcpdump. 1336 looks too small to me. What MTUs do you have 
around at the interfaces?

> My full config is posted here:
> My system:
> FreeBSD 6.1-RELEASE-p17
> MPD 4.1

MPD 4.2.2 was released some time ago.

> I played a bit with the above mentioned values with no luck unfortunately.
> I'm still wondering (don't know if I'm right) if a too large packet 
> comes from why doesn't it get fragmented upon being sent 
> via ng0 -> pptp1 and instead of this happening my machine sends an ICMP 
> unreachable back.

TCP packets usually have DF flag set which denies fragmentation. You can 
enable multilink PPP feature, it will give you complete 1500 bytes MTU 
and will process fragmentation by itself, but it will lead to bigger 
overhead and probably some lower peak performance.

Alexander Motin

More information about the freebsd-net mailing list