mirror of
https://github.com/openwrt/openwrt.git
synced 2025-03-13 15:56:55 +00:00
dropbear: increase default receive window size
Increasing the receive window size improves throughout on higher-latency links such as WAN connections. The current default of 24KB caps out at around 500 KB/s. Increasing the receive buffer to 256KB increases the throughput to at least 11 MB/s. Signed-off-by: David Bauer <mail@david-bauer.net>
This commit is contained in:
parent
fab15fa57e
commit
f95eecfb21
@ -155,6 +155,12 @@ dropbear_instance()
|
|||||||
PIDCOUNT="$(( ${PIDCOUNT} + 1))"
|
PIDCOUNT="$(( ${PIDCOUNT} + 1))"
|
||||||
local pid_file="/var/run/${NAME}.${PIDCOUNT}.pid"
|
local pid_file="/var/run/${NAME}.${PIDCOUNT}.pid"
|
||||||
|
|
||||||
|
# Increase default receive window size to increase
|
||||||
|
# throughput on high latency links
|
||||||
|
if [ "${RecvWindowSize}" -eq "0" ]; then
|
||||||
|
RecvWindowSize="262144"
|
||||||
|
fi
|
||||||
|
|
||||||
procd_open_instance
|
procd_open_instance
|
||||||
procd_set_param command "$PROG" -F -P "$pid_file"
|
procd_set_param command "$PROG" -F -P "$pid_file"
|
||||||
[ "${PasswordAuth}" -eq 0 ] && procd_append_param command -s
|
[ "${PasswordAuth}" -eq 0 ] && procd_append_param command -s
|
||||||
|
Loading…
x
Reference in New Issue
Block a user