Article 6QWED High UDP Packet Loss on WAN to LAN Forwarding with igmpproxy and nftables

High UDP Packet Loss on WAN to LAN Forwarding with igmpproxy and nftables

by
jic5760
from LinuxQuestions.org on (#6QWED)
I am configuring a Linux machine as a router. The kernel version is Linux 6.6.44. My network setup is as follows:

Code:WAN --- eth1 Router eth0 --- IPTV + PC
I am using igmpproxy and have set up nftables to forward traffic from WAN to LAN for the 224.0.0.0/4 multicast range by accepting it.

The issue Iim encountering is high UDP packet loss when forwarding traffic from WAN to LAN. The setup works, but the loss rate is high only in the WAN -> LAN direction.

The issue was reproduced in iperf as well as UDP Multicast.

Here are some details:
- When testing with iperf, WAN -> Router, Router -> LAN, and LAN -> WAN all work without any loss.
- The packet loss happens only in the forwarding direction (WAN -> LAN).
- Interestingly, there is no packet loss in the LAN -> WAN direction, even with SNAT applied.

CPU usage remains below 5%.

What could be causing this issue, and what should I check to troubleshoot further?

...

WAN -> Router : Good

Code:iperf3 -c speedtest.uztelecom.uz -u -p 5206 -R -b 50M
Connecting to host speedtest.uztelecom.uz, port 5206
Reverse mode, remote host speedtest.uztelecom.uz is sending
[ 5] local 175.198.43.100 port 41721 connected to 195.69.189.215 port 5206
[ ID] Interval Transfer Bitrate Jitter Lost/Total Datagrams
[ 5] 0.00-1.00 sec 5.91 MBytes 49.6 Mbits/sec 0.018 ms 61/4343 (1.4%)
[ 5] 1.00-2.00 sec 5.96 MBytes 50.0 Mbits/sec 0.018 ms 0/4316 (0%)
[ 5] 2.00-3.00 sec 5.96 MBytes 50.0 Mbits/sec 0.021 ms 0/4316 (0%)
[ 5] 3.00-4.00 sec 5.94 MBytes 49.8 Mbits/sec 0.017 ms 19/4317 (0.44%)
[ 5] 4.00-5.00 sec 5.87 MBytes 49.2 Mbits/sec 0.008 ms 65/4316 (1.5%)
[ 5] 5.00-6.00 sec 5.96 MBytes 50.0 Mbits/sec 0.018 ms 0/4316 (0%)
[ 5] 6.00-7.00 sec 5.96 MBytes 50.0 Mbits/sec 0.017 ms 0/4316 (0%)
[ 5] 7.00-8.00 sec 5.96 MBytes 50.0 Mbits/sec 0.018 ms 0/4318 (0%)
[ 5] 8.00-9.00 sec 5.96 MBytes 50.0 Mbits/sec 0.017 ms 0/4319 (0%)
[ 5] 9.00-10.00 sec 5.96 MBytes 50.0 Mbits/sec 0.015 ms 0/4313 (0%)
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bitrate Jitter Lost/Total Datagrams
[ 5] 0.00-10.00 sec 60.8 MBytes 51.0 Mbits/sec 0.000 ms 0/0 (0%) sender
[ 5] 0.00-10.00 sec 59.4 MBytes 49.9 Mbits/sec 0.015 ms 145/43190 (0.34%) receiverRouter to PC: Good

Code:iperf3 -c 192.168.0.11 -u -R -b 25M
Connecting to host 192.168.0.11, port 5201
Reverse mode, remote host 192.168.0.11 is sending
[ 5] local 192.168.0.196 port 49821 connected to 192.168.0.11 port 5201
[ ID] Interval Transfer Bitrate Jitter Lost/Total Datagrams
[ 5] 0.00-1.01 sec 2.99 MBytes 24.9 Mbits/sec 0.625 ms 0/2145 (0%)
[ 5] 1.01-2.02 sec 2.97 MBytes 24.6 Mbits/sec 0.722 ms 0/2135 (0%)
[ 5] 2.02-3.01 sec 3.01 MBytes 25.6 Mbits/sec 0.061 ms 1/2164 (0.046%)
[ 5] 3.01-4.00 sec 2.97 MBytes 25.0 Mbits/sec 0.154 ms 0/2133 (0%)
[ 5] 4.00-5.00 sec 2.97 MBytes 25.0 Mbits/sec 0.186 ms 0/2136 (0%)
[ 5] 5.00-6.00 sec 2.97 MBytes 25.0 Mbits/sec 0.288 ms 0/2135 (0%)
[ 5] 6.00-7.00 sec 2.99 MBytes 25.1 Mbits/sec 0.227 ms 0/2148 (0%)
[ 5] 7.00-8.00 sec 2.97 MBytes 25.0 Mbits/sec 0.178 ms 0/2134 (0%)
[ 5] 8.00-9.02 sec 3.03 MBytes 25.0 Mbits/sec 0.198 ms 0/2173 (0%)
[ 5] 9.02-10.01 sec 2.97 MBytes 25.0 Mbits/sec 0.223 ms 0/2136 (0%)
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bitrate Jitter Lost/Total Datagrams
[ 5] 0.00-10.02 sec 29.9 MBytes 25.0 Mbits/sec 0.000 ms 0/21439 (0%) sender
[ 5] 0.00-10.01 sec 29.8 MBytes 25.0 Mbits/sec 0.223 ms 1/21439 (0.0047%) receiverWAN to PC: BAD

Code:iperf3 -c speedtest.uztelecom.uz -u -p 5206 -R -b 10M
Connecting to host speedtest.uztelecom.uz, port 5206
Reverse mode, remote host speedtest.uztelecom.uz is sending
[ 5] local 192.168.0.196 port 55865 connected to 195.69.189.215 port 5206
[ ID] Interval Transfer Bitrate Jitter Lost/Total Datagrams
[ 5] 0.00-1.01 sec 867 KBytes 7.05 Mbits/sec 0.063 ms 245/853 (29%)
[ 5] 1.01-2.01 sec 814 KBytes 6.64 Mbits/sec 0.063 ms 286/857 (33%)
[ 5] 2.01-3.01 sec 880 KBytes 7.18 Mbits/sec 0.037 ms 240/857 (28%)
[ 5] 3.01-4.01 sec 897 KBytes 7.41 Mbits/sec 0.115 ms 226/855 (26%)
[ 5] 4.01-5.00 sec 764 KBytes 6.28 Mbits/sec 0.132 ms 313/849 (37%)
[ 5] 5.00-6.01 sec 831 KBytes 6.77 Mbits/sec 0.125 ms 278/861 (32%)
[ 5] 6.01-7.01 sec 960 KBytes 7.83 Mbits/sec 0.034 ms 190/863 (22%)
[ 5] 7.01-8.00 sec 808 KBytes 6.68 Mbits/sec 0.113 ms 285/852 (33%)
[ 5] 8.00-9.00 sec 806 KBytes 6.61 Mbits/sec 0.171 ms 283/848 (33%)
[ 5] 9.00-10.01 sec 753 KBytes 6.11 Mbits/sec 0.118 ms 323/851 (38%)
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bitrate Jitter Lost/Total Datagrams
[ 5] 0.00-10.01 sec 12.2 MBytes 10.2 Mbits/sec 0.000 ms 0/0 (0%) sender
[ 5] 0.00-10.01 sec 8.18 MBytes 6.86 Mbits/sec 0.118 ms 2669/8546 (31%) receiverPC to WAN: Good
Code:iperf3 -c speedtest.uztelecom.uz -u -p 5206 -b 10M
Connecting to host speedtest.uztelecom.uz, port 5206
[ 5] local 192.168.0.196 port 65129 connected to 195.69.189.215 port 5206
[ ID] Interval Transfer Bitrate Total Datagrams
[ 5] 0.00-1.00 sec 1.18 MBytes 9.86 Mbits/sec 844
[ 5] 1.00-2.01 sec 1.20 MBytes 9.99 Mbits/sec 861
[ 5] 2.01-3.01 sec 1.20 MBytes 10.0 Mbits/sec 862
[ 5] 3.01-4.00 sec 1.18 MBytes 9.99 Mbits/sec 849
[ 5] 4.00-5.01 sec 1.20 MBytes 10.0 Mbits/sec 862
[ 5] 5.01-6.01 sec 1.20 MBytes 10.0 Mbits/sec 859
[ 5] 6.01-7.00 sec 1.18 MBytes 10.0 Mbits/sec 847
[ 5] 7.00-8.01 sec 1.20 MBytes 10.0 Mbits/sec 864
[ 5] 8.01-9.01 sec 1.19 MBytes 10.0 Mbits/sec 853
[ 5] 9.01-10.00 sec 1.18 MBytes 9.99 Mbits/sec 849
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bitrate Jitter Lost/Total Datagrams
[ 5] 0.00-10.00 sec 11.9 MBytes 9.98 Mbits/sec 0.000 ms 0/8550 (0%) sender
[ 5] 0.00-10.00 sec 11.9 MBytes 9.98 Mbits/sec 0.066 ms 0/8550 (0%) receiver
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments