Hello,
I’m running two routers that are connected via IPSec like in this documentation with the GRE tunnel.
I had a problem where some connections from a device behind one router, to the internet routed through the other router, like ping or http (sometimes) would work but others like https would fail.
I tracked this down to a MTU issue along the path - specifically when the Sever Hello of the TLS negotiation would not reach the client on the way back.
I then looked at the tun0 interface with Wireshark on the router connected to the internet and can see ICMPs like this (192.168.250.2 is the loopback address):
23 450.734457 192.168.250.2 192.168.250.2 ICMP 590 Destination unreachable (Fragmentation needed)
Even though the original packed did not have the DF bit set, the GRE packet does have it set.
The GRE Packet is 1476 bytes in length which is the same as the MTU Setting on the interface. Behaviour is no different whether this value is set by hand or the default is used.
In reality the biggest packet I could send was 1414 bytes:
dracotomes@client:~$ ping google.de -s 1385
PING google.de (142.251.209.131) 1385(1413) bytes of data.
76 bytes from ham11s07-in-f3.1e100.net (142.251.209.131): icmp_seq=1 ttl=116 (truncated)
76 bytes from ham11s07-in-f3.1e100.net (142.251.209.131): icmp_seq=2 ttl=116 (truncated)
^C
--- google.de ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1002ms
rtt min/avg/max/mdev = 21.324/21.503/21.683/0.179 ms
dracotomes@client:~$ ping google.de -s 1386
PING google.de (142.251.209.131) 1386(1414) bytes of data.
76 bytes from ham11s07-in-f3.1e100.net (142.251.209.131): icmp_seq=1 ttl=116 (truncated)
76 bytes from ham11s07-in-f3.1e100.net (142.251.209.131): icmp_seq=2 ttl=116 (truncated)
^C
--- google.de ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1002ms
rtt min/avg/max/mdev = 21.340/21.372/21.404/0.032 ms
dracotomes@client:~$ ping google.de -s 1387
PING google.de (142.251.209.131) 1387(1415) bytes of data.
^C
--- google.de ping statistics ---
6 packets transmitted, 0 received, 100% packet loss, time 5098ms
The version on both routers is:
Version: VyOS 1.5-rolling-202310240118
Release train: current
Built by: autobuild@vyos.net
Built on: Tue 24 Oct 2023 02:41 UTC
Build UUID: 66471dfc-8348-4dbf-953e-133854c539ff
Build commit ID: 142e8770563716
Architecture: x86_64
Boot via: installed image
System type: KVM guest
Hardware vendor: QEMU
Hardware model: Standard PC (i440FX + PIIX, 1996)
Hardware S/N:
Hardware UUID: df3bd66b-a30a-42e2-a824-57439af15abb
Copyright: VyOS maintainers and contributors
I have set the MTU size on the tun0 Interfaces to 8024 and everything seems to work right now.
I feel like this should work out of the box, or did I make a mistake in the configuration?