From 9e10f07fa6fd88f473ccce2cc9acb00112d07ed8 Mon Sep 17 00:00:00 2001 From: Ycarus Date: Thu, 27 Sep 2018 10:50:46 +0200 Subject: [PATCH] Increase timeout for glorytun, decrease txqueuelen for interfaces --- glorytun/init | 4 ++-- mptcp/files/etc/init.d/mptcp | 1 + shadowsocks-libev/files/shadowsocks.conf | 4 ++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/glorytun/init b/glorytun/init index f8c6a8855..929bf1398 100755 --- a/glorytun/init +++ b/glorytun/init @@ -75,9 +75,9 @@ start_instance() { [ "${chacha20}" = "1" ] && procd_append_param command chacha20 procd_append_param command \ - retry count -1 const 500000 \ + retry count -1 const 5000000 \ timeout 40000 \ - keepalive count 5 idle 30 interval 2 \ + keepalive count 5 idle 10 interval 2 \ buffer-size 32768 procd_set_param respawn 0 30 0 diff --git a/mptcp/files/etc/init.d/mptcp b/mptcp/files/etc/init.d/mptcp index ab07610ec..815af4a03 100755 --- a/mptcp/files/etc/init.d/mptcp +++ b/mptcp/files/etc/init.d/mptcp @@ -97,6 +97,7 @@ interface_multipath_settings() { [ "$mode" = "master" ] && { ip route replace default via $gateway dev $iface } + ifconfig $iface txqueuelen 90 > /dev/null 2>&1 } load_interfaces() { diff --git a/shadowsocks-libev/files/shadowsocks.conf b/shadowsocks-libev/files/shadowsocks.conf index b46b807c2..7de9c7b37 100644 --- a/shadowsocks-libev/files/shadowsocks.conf +++ b/shadowsocks-libev/files/shadowsocks.conf @@ -6,9 +6,9 @@ net.core.rmem_max = 134217728 # max write buffer net.core.wmem_max = 134217728 # default read buffer -net.core.rmem_default = 65536 +net.core.rmem_default = 32768 # default write buffer -net.core.wmem_default = 65536 +net.core.wmem_default = 32768 # max processor input queue net.core.netdev_max_backlog = 4096 # max backlog