Skip to content

Instantly share code, notes, and snippets.

@rodhfr
Created December 14, 2025 04:39
Show Gist options
  • Select an option

  • Save rodhfr/3ef47df1d576cda26613f2dfcd944d2b to your computer and use it in GitHub Desktop.

Select an option

Save rodhfr/3ef47df1d576cda26613f2dfcd944d2b to your computer and use it in GitHub Desktop.
sudo nano /usr/local/bin/tailscale-ethtool.sh
---
#!/bin/bash
# Detect primary network interface
NETDEV=$(ip -o route get 8.8.8.8 | awk '{print $5}')
# Apply Tailscale UDP GRO optimization
/usr/sbin/ethtool -K $NETDEV rx-udp-gro-forwarding on rx-gro-list off
---
sudo chmod +x /usr/local/bin/tailscale-ethtool.sh
sudo nano /etc/systemd/system/tailscale-ethtool.service
---
[Unit]
Description=Optimize UDP GRO for Tailscale
After=network-online.target
Wants=network-online.target
[Service]
Type=oneshot
ExecStart=/usr/local/bin/tailscale-ethtool.sh
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
sudo systemctl daemon-reload
sudo systemctl enable tailscale-ethtool
sudo systemctl start tailscale-ethtool
---
systemctl status tailscale-ethtool
# test
NETDEV=$(ip -o route get 8.8.8.8 | awk '{print $5}')
ethtool -k $NETDEV | grep rx-udp-gro-forwarding
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment