提交 87f94af1 编写于 作者: S small_5 提交者: coolsnowwolf

Update autocore (#2571)

上级 ec09a3ec
......@@ -35,29 +35,20 @@ start()
mkdir -p /tmp/sysinfo
echo $g > /tmp/sysinfo/model
ethtool -K eth0 rx-checksum on >/dev/null 2>&1
ethtool -K eth0 tx-checksum-ip-generic on >/dev/null 2>&1
ethtool -K eth0 tso on >/dev/null 2>&1
ethtool -K eth0 ufo on >/dev/null 2>&1
ethtool -K eth0 gso on >/dev/null 2>&1
ethtool -K eth1 rx-checksum on >/dev/null 2>&1
ethtool -K eth1 tx-checksum-ip-generic on >/dev/null 2>&1
ethtool -K eth1 tso on >/dev/null 2>&1
ethtool -K eth1 ufo on >/dev/null 2>&1
ethtool -K eth1 gso on >/dev/null 2>&1
ethtool -K eth2 rx-checksum on >/dev/null 2>&1
ethtool -K eth2 tx-checksum-ip-generic on >/dev/null 2>&1
ethtool -K eth2 tso on >/dev/null 2>&1
ethtool -K eth2 ufo on >/dev/null 2>&1
ethtool -K eth2 gso on >/dev/null 2>&1
ethtool -K eth3 rx-checksum on >/dev/null 2>&1
ethtool -K eth3 tx-checksum-ip-generic on >/dev/null 2>&1
ethtool -K eth3 tso on >/dev/null 2>&1
ethtool -K eth3 ufo on >/dev/null 2>&1
ethtool -K eth3 gso on >/dev/null 2>&1
a=$(ip address | grep ^[0-9] | awk -F: '{print $2}' | sed "s/ //g" | grep '^[e]' | grep -v "@" | grep -v "\.")
b=$(echo "$a" | wc -l)
for i in $(seq 1 $b)
do
c=$(echo "$a" | sed -n ${i}p)
ethtool -K $c rx-checksum on >/dev/null 2>&1
ethtool -K $c tx-checksum-ip-generic on >/dev/null 2>&1 || (
ethtool -K $c tx-checksum-ipv4 on >/dev/null 2>&1
ethtool -K $c tx-checksum-ipv6 on >/dev/null 2>&1)
ethtool -K $c tx-scatter-gather on >/dev/null 2>&1
ethtool -K $c gso on >/dev/null 2>&1
ethtool -K $c tso on >/dev/null 2>&1
ethtool -K $c ufo on >/dev/null 2>&1
done
[ -f /etc/index.htm ] && mv /etc/index.htm /usr/lib/lua/luci/view/admin_status/index.htm
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册