4

My upload and download speeds on my seedbox hosted on my pi constantly fluctuated between 2.5MBps and 50/0KBps. I have done file download speed tests and get upwards of 3.3Mbps, yet even on the best seeded torrents my dl/up speed soars for a couple of seconds, then abruptly grinds to a halt for another few.

So far I have found this thread, which describes my problem accurately, but it doesn't come to a decisive answer.

I have already tried changing all the settings in Deluge, and even used transmission on my pi to no avail. I've checked the CPU and memory usage so it can't be that, maybe the power supply??

I am downloading to an external USB flash drive so that could be the issue, if so how could I check the read and write speeds?

I have also torrented on my computer on my home network so I doubt it could be my ISP throttling p2p connections.

Does anybody know why this could be, or have resolved a similar issue when torrenting with a raspberry pi?

EDIT 1:

Just added some more really well seeded torrents and observed the download speed. Even with 173 seeders and 0 peers still maxed out around 1MBps then fell to around 50KBps. Could it be that my router is sending too many packets for my pi to handle?

EDIT 2:

After changing to transmission and tweaking the settings a little I found this problem to go away. I think the deluge in the raspi-repo is outdated, and I would recommend anyone who is having the similar problems to do the same.

Carlo Revelli
  • 123
  • 1
  • 8

2 Answers2

3

Their are many possible problems that could lead to a slow download speed.

  1. It could be because of the limited number of connections you can make, often the other people you are downloading from will have very limited upload speed, and a decent upload speed is only created with a lot of connections, sadly the Pi is not capable of handling a lot of connections so sometimes you will get lucky and connect with someone who has a higher upload speed than usual who will allow the Pi to download faster without the need for more connections to be opened. Note: I personally find that limiting connections to something like 20-50 and bandwidth to something like 1mbps prevents connections from timing out and also prevents Ethernet from challenging the USB ports for bandwidth.
  2. It may also be due to the fact that most torrent clients download to ram then flush when it's full which may be the slowdown that you are noticing on the Pi. Furthermore when said cache in memory is flushed it must be flushed to the usb drive which you are using, which just so happens to share the same bus as the ethernet port as the Pi does not have a native Ethernet port but instead a usb hub with Ethernet adapter built in. Furthermore torrenting has always been rather slow on the Pi due to the nature of torrenting requiring the Pi to use a checksum included in the torrent file to ensure that you aren't being sent the wrong chunk from someone.
  3. You may also be using encrypted torrenting which although prevents man in the middle attacks also has an incredibly detrimental effect on download and upload speeds as a lot more steps are added to the torrenting process such as, key negotiation, the location of a suitable client (one that also wishes to use encryption) and then all packets must then be decrypted at a snails pace.
  4. Finally if you are using a Pi with less than a gigabyte of ram I strongly recommend you upgrade as the difference will be noticing everyone as more ram will eleviate some of the need for writing to your sub thus freeing up the usb bus for the Ethernet port.
  5. Note: If you are on transmission be sure that you set your preferred download speed on the bottom left and be sure that the turtle has not been selected as selecting the turtle will lead to a default download speed of 50kbps which is what you are describing.
Mohammad Ali
  • 2,373
  • 1
  • 12
  • 18
-2

Don't listen to Ali. You clearly have a disk problem. Either "full" disk or problems to write to disk. I suspect your USB drive is to blame and you need a new one. Your write speed is slowing down because only smaller and smaller files find enough write space on the (full) disk. Thus the diminishing returns and speed.

SamTzu
  • 1
  • 2