radxa / device-rockchip-rk3399

3 stars 0 forks source link

Network error when TCP offload is enabled with RK3399 #1

Open myroad94 opened 2 years ago

myroad94 commented 2 years ago

Hi,

Not sure if this is the correct place to open this issue. With Rock PI 4C containing RK3399 chip, the network has lots of error if TCP offload is not disabled.

Workaround: Disable it with (immediate effect + persistent in reboot)

cat <<EOF | sudo tee /etc/network/if-up.d/disable-offload
#!/bin/sh
# TCP offloading must be disabled because of RK3399 bug.
# See https://unix.stackexchange.com/questions/494290/nanopi-m4-rk3399-apache2-ssl-large-download-hangs/495378#495378
# See https://help.nextcloud.com/t/download-aborts-after-time-or-large-file/25044/5
/sbin/ethtool -K eth0 rx off tx off

EOF
sudo chmod 755 /etc/network/if-up.d/disable-offload
sudo /etc/network/if-up.d/disable-offload

Long-term solution: Correct the network driver to allow TCP offload? I guess the workaround will affect the network performance and CPU negatively.

myroad94 commented 2 years ago

For more info, see https://github.com/MichaIng/DietPi/issues/2028 https://tadeubento.com/2019/nanopi-m4-rk3399-network-issues/ https://forum.armbian.com/topic/13544-nanopi-m4-and-other-rk3399-need-tcpudp-offloading-disabled/