NICMx / Jool

SIIT and NAT64 for Linux
GNU General Public License v2.0
328 stars 66 forks source link

NAT64 session state replication does not work on kernel 5.10 #362

Closed sysvinit closed 3 years ago

sysvinit commented 3 years ago

I'm running Jool 4.1.5 on a pair of Debian Buster machines, and (in the same arrangement as #352) both are performing NAT64 translation with Jool, and using joold to replicate session state between themselves.

Previously, I was running an old 4.9-series kernel on these machines, and session state replication worked correctly, however I have since upgraded to a 5.10-series kernel from the buster-backports repository, and session state replication no longer works.

I have attempted to ping a v6-translated v4 address from a v6-only machine behind the translators, and while the session state on the egress router is visible with jool session display --numeric --icmp, the session is not replicated to the second router, as the session is not visible with the same command. I see the following message in the first router's logs:

May 26 14:27:50 lathe joold: Error receiving packet from kernelspace: Invalid input data or parameter                                                                  
May 26 14:27:50 lathe joold: Error receiving packet from kernelspace: Invalid input data or parameter                                                                  
May 26 14:27:51 lathe joold: Error receiving packet from kernelspace: Invalid input data or parameter
May 26 14:27:51 lathe joold: Error receiving packet from kernelspace: Invalid input data or parameter
May 26 14:27:52 lathe joold: Error receiving packet from kernelspace: Invalid input data or parameter
May 26 14:27:52 lathe joold: Error receiving packet from kernelspace: Invalid input data or parameter
May 26 14:27:53 lathe joold: Error receiving packet from kernelspace: Invalid input data or parameter
May 26 14:27:53 lathe joold: Error receiving packet from kernelspace: Invalid input data or parameter
May 26 14:27:54 lathe joold: Error receiving packet from kernelspace: Invalid input data or parameter

[Due to external factors, I have limited time to look into this at present, so if more information is required it might take some time until I'm able to investigate further.]

ydahhrk commented 3 years ago

Did you check the versions match?

$ jool --version
4.1.5.0
$ dmesg | grep "module inserted"
NAT64 Jool v4.1.5.0 module inserted.
sysvinit commented 3 years ago

Yes, the versions of the kernel module and the userspace tools match. The only thing I changed was the kernel version (from 4.9 to 5.10), and I have DKMS set up to build the appropriate version of the kernel module automatically.

ydahhrk commented 3 years ago

Ok. I did manage to reproduce it; will debug tomorrow.

ydahhrk commented 3 years ago

@sysvinit: The bug is most likely fixed. Please verify.

sysvinit commented 3 years ago

I can confirm that this bug has been fixed -- thanks for looking into this so quickly!