EPC 장비 OS 상 Traffic offload 옵션 이슈 - netipark/t_lte GitHub Wiki

  • 문제 현상

    • 외부망으로부터 MTU 이하(<1500byte) 사이즈로 TCP 패킷을 수신 받았으나, EPC 상에서 tcpdump를 수행해 보면 수만 byte 크기의 패킷이 잡혀 있음
  • 해결 방법

    • EPC start 스크립트에 아래 옵션 변경을 커맨드를 추가하여 traffic offload 기능을 비활성화 함
#!/bin/bash
LOCKFILE_PATH=/tmp/lock.onepc.file

if [ -f $LOCKFILE_PATH ];
then
        echo "already ONEPC is running..."
        exit
fi

echo $$ > $LOCKFILE_PATH

#sudo service iptables stop
sudo ethtool --offload eth0 rx off tx off
sudo ethtool --offload eth1 rx off tx off
sudo ethtool -K eth0 gso off
sudo ethtool -K eth1 gso off
sudo ethtool -K eth0 gro off
sudo ethtool -K eth1 gro off

# 505 : status, 506 : alarm
echo 505 > /sys/class/gpio/export
echo 506 > /sys/class/gpio/export

cd /home/eucast/ONEPC/02_bin

iptables -F
iptables -D INPUT -p icmp --icmp-type redirect -j DROP
iptables -D INPUT -p icmp --icmp-type destination-unreachable -j DROP
iptables -A INPUT -p icmp --icmp-type redirect -j DROP
iptables -A INPUT -p icmp --icmp-type destination-unreachable -j DROP