linuxserver / docker-transmission

GNU General Public License v3.0
594 stars 184 forks source link

Very slow disk I/O #178

Closed jaytrinitron closed 2 years ago

jaytrinitron commented 3 years ago

I am not sure this is an issue, maybe it is something with my personal setup. I have found so far that disk I/O activities take forever from the docker container, and I'm not sure why. Particularly, verification takes much longer than it should. While it does peg one thread at 85-100% usage, I believe transmission's lack of multithreading is unrelated, because a transmission instance installed on bare metal performs quite well in comparison (8-10x speed). Disk activity does not seem to go higher than 20MB/s, and is usually closer to 10-15. My internet download speed is fast enough that disk I/O is usually the bottleneck, provided the torrent has high-speed/many seeders. Is there a setting I can try to fix this? It happened on my old system as well, and I just chalked it up to it being extremely old. But my new system should not be disk I/O limited to this extent. What gives?

Edit: So after monitoring it seems like for very large torrents the disk read starts out high enough (around 100MB/s) before dropping off over time. My disks are not full, and the highest speed is still about half of what I get on bare metal.

github-actions[bot] commented 3 years ago

Thanks for opening your first issue here! Be sure to follow the bug or feature issue templates!

jaytrinitron commented 3 years ago

Just checked. For bare metal transmission-daemon for the same size or larger torrents (hundreds of GB), this slow down does not occur and I'm able to max out my disk read of ~200MB/s all the way through. Why do I have I/O speed issues with the docker container?

j0nnymoe commented 3 years ago

You've ignored our issue template where we ask information about your setup... We aren't able to help without that.

jaytrinitron commented 3 years ago

Sorry about that, for some reason it didn’t autofill a template and I didn’t realize when looking at past issues.

linuxserver.io


Expected Behavior

Transmission in docker has roughly the same read and write speed as transmission on bare metal.

Current Behavior

For verification of large (multiple hundreds of GB) torrents, docker transmission starts out at normal speed (200 MB/s) before dropping speed over time to a crawl (15 MB/s)

Steps to Reproduce

  1. Get a very large torrent and verify
  2. Compare against speed of native transmission for the same process

Environment

OS: Ubuntu 20.04.3 LTS CPU architecture: x86_64 How docker service was installed: from the official docker repo

Command used to create docker container (run/create/compose/screenshot)

sudo docker create \ --name=transmission4 \ -e PUID=1000 \ -e PGID=1000 \ -e TZ=time/zone \ -e TRANSMISSION_WEB_HOME=/combustion-release/ #optional \ -e USER=usre #optional \ -e PASS=pw #optional \ -p 9096:9096 \ -p 51418:51418 \ -p 51418:51418/udp \ -v /home/docker/transmission4/config:/config \ -v /mnt/storage/:/downloads \ --restart unless-stopped \ linuxserver/transmission

Docker logs

[s6-init] making user provided files available at /var/run/s6/etc...exited 0. [s6-init] ensuring user provided files have correct perms...exited 0. [fix-attrs.d] applying ownership & permissions fixes... [fix-attrs.d] done. [cont-init.d] executing container initialization scripts... [cont-init.d] 01-envfile: executing... [cont-init.d] 01-envfile: exited 0. [cont-init.d] 10-adduser: executing...


      _         ()
     | |  ___   _    __
     | | / __| | |  /  \ 
     | | \__ \ | | | () |
     |_| |___/ |_|  \__/

Brought to you by linuxserver.io

To support LSIO projects visit: https://www.linuxserver.io/donate/

GID/UID

User uid: 1000 User gid: 1000

[cont-init.d] 10-adduser: exited 0. [cont-init.d] 20-config: executing... [cont-init.d] 20-config: exited 0. [cont-init.d] 90-custom-folders: executing... [cont-init.d] 90-custom-folders: exited 0. [cont-init.d] 99-custom-files: executing... [custom-init] no custom files found exiting... [cont-init.d] 99-custom-files: exited 0. [cont-init.d] done. [services.d] starting services [services.d] done. Caught SIGTERM signal! Tell the transmission session to shut down. [s6-init] making user provided files available at /var/run/s6/etc...exited 0. [s6-init] ensuring user provided files have correct perms...exited 0. [fix-attrs.d] applying ownership & permissions fixes... [fix-attrs.d] done. [cont-init.d] executing container initialization scripts... [cont-init.d] 01-envfile: executing... [cont-init.d] 01-envfile: exited 0. [cont-init.d] 10-adduser: executing... usermod: no changes


      _         ()
     | |  ___   _    __
     | | / __| | |  /  \ 
     | | \__ \ | | | () |
     |_| |___/ |_|  \__/

Brought to you by linuxserver.io

To support LSIO projects visit: https://www.linuxserver.io/donate/

GID/UID

User uid: 1000 User gid: 1000

[cont-init.d] 10-adduser: exited 0. [cont-init.d] 20-config: executing... [cont-init.d] 20-config: exited 0. [cont-init.d] 90-custom-folders: executing... [cont-init.d] 90-custom-folders: exited 0. [cont-init.d] 99-custom-files: executing... [custom-init] no custom files found exiting... [cont-init.d] 99-custom-files: exited 0. [cont-init.d] done. [services.d] starting services [services.d] done.

j0nnymoe commented 3 years ago

Thanks, you still haven't provided any info on how you've deployed the container as in docker-compose etc.

jaytrinitron commented 3 years ago

Thanks, you still haven't provided any info on how you've deployed the container as in docker-compose etc.

Yeah I know, I'm working on the rest.

j0nnymoe commented 3 years ago

Are you checking cpu usage and io usage while the transfer is slowing down?

jaytrinitron commented 3 years ago

Are you checking cpu usage and io usage while the transfer is slowing down?

Yes, io usage drops very low as this happens, CPU usage varies but starts out at perhaps 50-70% on one thread before increasing to 80-95%. I thought initially this may be because transmission isn't multithreaded, but the native daemon has no such issues and my I/O is saturated before my CPU is.

j0nnymoe commented 3 years ago

It's probably how you've got your volumes setup. If it's 2 separate mounts, it's gonna cause more io.

jaytrinitron commented 3 years ago

It's probably how you've got your volumes setup. If it's 2 separate mounts, it's gonna cause more io. Thanks, but I don’t think that’s it. It is two separate drives merged with mergerFS, but both transmission native and transmission docker are reading from the same place for verification, so I don’t think that explains the difference. Besides, I/O is actually much lower with the docker container after some time. And it’s fine for smaller torrents but struggles on larger ones. On Oct 16, 2021, 8:06 AM -0700, j0nnymoe @.***>, wrote: It's probably how you've got your volumes setup. If it's 2 separate mounts, it's gonna cause more io. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

github-actions[bot] commented 2 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

thelamer commented 2 years ago

We install transmission from Alpine's repos. I am just stating that to break down what we do here is not exactly rocket science. I can appreciate that you are having a real issue while running this in Docker vs running it natively, but I do not believe we will be able to resolve this issue by making modifications to this codebase.