Subject: Re: MSS doesn't honour route MTU
To: Quentin Garnier <cube@cubidou.net>
From: Mihai CHELARU <kefren@netbsd.ro>
List: tech-net
Date: 06/08/2006 21:23:43
----- Original Message ----- 
From: "Quentin Garnier" <cube@cubidou.net>
To: "Mihai CHELARU" <kefren@netbsd.ro>
Cc: <tech-net@netbsd.org>
Sent: Thursday, June 08, 2006 9:11 PM
Subject: Re: MSS doesn't honour route MTU

> Not unless you set net.inet.tcp.mss_ifmtu to 1.

No, it's the same:

mpls# sysctl net.inet.tcp.mss_ifmtu
net.inet.tcp.mss_ifmtu = 1
mpls# tcpdump -p -l -n -vvv host 198.133.219.25 > dump &
[1] 2168
mpls# tcpdump: listening on xennet0, link-type EN10MB (Ethernet), capture 
size 96 bytes

mpls# telnet -NK 198.133.219.25 80
Trying 198.133.219.25...
Connected to 198.133.219.25.
Escape character is '^]'.
^]
telnet> q
Connection closed.
mpls# kill %1
5 packets captured
520 packets received by filter
0 packets dropped by kernel
[1]    Done                   tcpdump -p -l -n -vvv host 198.133.219.25 > 
dump
mpls# head dump
20:41:58.842122 IP (tos 0x0, ttl  64, id 5599, offset 0, flags [DF], length: 
64) 193.28.151.36.65525 > 198.133.219.25.80: S [tcp sum ok] 
3549217263:3549217263(0) win 32768 <mss 1460,nop,wscale 
0,sackOK,nop,nop,nop,nop,timestamp 0 0>
20:41:59.035936 IP (tos 0x0, ttl 241, id 11, offset 0, flags [none], length: 
44) 198.133.219.25.80 > 193.28.151.36.65525: S [tcp sum ok] 
3243049920:3243049920(0) ack 3549217264 win 8192 <mss 1460>
20:41:59.035983 IP (tos 0x0, ttl  64, id 5600, offset 0, flags [DF], length: 
40) 193.28.151.36.65525 > 198.133.219.25.80: . [tcp sum ok] 1:1(0) ack 1 win 
33580
20:41:59.961690 IP (tos 0x0, ttl  64, id 5606, offset 0, flags [DF], length: 
40) 193.28.151.36.65525 > 198.133.219.25.80: F [tcp sum ok] 1:1(0) ack 1 win 
33580
20:42:00.157903 IP (tos 0x0, ttl 241, id 12, offset 0, flags [none], length: 
40) 198.133.219.25.80 > 193.28.151.36.65525: R [tcp sum ok] 1:1(0) ack 1 win 
33580

mpls# route -n get 198.133.219.25
   route to: 198.133.219.25
destination: 198.133.219.25
    gateway: 193.28.151.1
 local addr: 193.28.151.36
  interface: xennet0
      flags: <UP,GATEWAY,HOST,DONE,STATIC>
 recvpipe  sendpipe  ssthresh  rtt,msec    rttvar  hopcount      mtu 
expire
       0         0         0         0         0         0      1200 
0


Btw, why is this mss_ifmtu set to 0 ? I don't think it has any reason to 
exist at all. And not at all set 0 by default. Why would I want to respond 
to a packet received on a interface with MTU-40 of other interface ? Do I 
expect that flow to automagically be received on great_mtu interface ?

-- 
Mihai