From dcc9df3a5fd4ae70fd80a1252b1e1b4d7c350195 Mon Sep 17 00:00:00 2001 From: stickz Date: Sun, 21 May 2023 13:04:20 -0400 Subject: [PATCH] rTorrent: Network configuration This commit suggests implementation of a 4MB send and receive buffer for TCP sockets to improve throughput on gigabit connections. It explains why they are disabled by default on rTorrent and how much memory is consumed. It also adds a missing configuration variable for per torrent upload slots. The default value of 50 is applied. --- scripts/install/rtorrent.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/scripts/install/rtorrent.sh b/scripts/install/rtorrent.sh index dfd989a6c..6c99733e3 100755 --- a/scripts/install/rtorrent.sh +++ b/scripts/install/rtorrent.sh @@ -33,11 +33,21 @@ throttle.global_down.max_rate.set = 0 throttle.global_up.max_rate.set = 0 throttle.max_peers.normal.set = 100 throttle.max_peers.seed.set = -1 +throttle.max_uploads.set = 50 throttle.max_uploads.global.set = 100 throttle.min_peers.normal.set = 1 throttle.min_peers.seed.set = -1 trackers.use_udp.set = yes +# Disabled by default becuase these will override Linux Kernel settings +# Suggested to configure on a per application basis to improve throughput +# +# 4MB per TCP socket is the most ideal setting to balance memory consumption +# 100 upload slots will consume 400MB of memory and stabilize gigabit upload speeds +# +#network.send_buffer.size.set = 4M +#network.receive_buffer.size.set = 4M + execute = {sh,-c,/usr/bin/php /srv/rutorrent/php/initplugins.php ${user} &} # -- END HERE --