Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Huge memory consumption #311

Open
1 task done
molotovah opened this issue Jun 4, 2024 · 10 comments
Open
1 task done

[BUG] Huge memory consumption #311

molotovah opened this issue Jun 4, 2024 · 10 comments

Comments

@molotovah
Copy link

molotovah commented Jun 4, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

High RAM consumption until Out of memory

Expected Behavior

RAM consumption should be low

Steps To Reproduce

  1. Download Torrent
  2. Ram is increasing until OOM

Environment

- qBittorrent: 4.6.5
- Libtorrent: 2.0.10.0
- QT: 6.6.3
- Docker: 26.1.3
- Image: linuxserver/qbittorrent:4.6.5
- OS:Ubuntu 22.04
- How docker service was installed: with portainer

CPU architecture

x86-64

Docker creation

networks:
  download-station:
    external: true

services:   
  qbittorrent:
    image: lscr.io/linuxserver/qbittorrent:latest
    container_name: qbittorrent
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Europe/Paris
      - WEBUI_PORT=9080
      - TORRENTING_PORT=6881
    volumes:
      - /home/user/docker-data/qbittorrent/config:/config
      - /home/user/docker-data/qbittorrent/plugins:/plugins
      - /media/freebox/Torrents/downloads:/downloads
      - /media/freebox/Torrents/watch:/watch
      - /media/freebox/Torrents/Torrent_Files:/torrent
    ports:
      # QBittorrent
      - 1080:1080 # Socks5 Proxy
      - 9080:9080 # Web Interface
      - 9566:9566/udp
      - 6881:6881/udp   
    restart: unless-stopped
    networks:
      - download-station

Container logs

───────────────────────────────────────
      ██╗     ███████╗██╗ ██████╗
      ██║     ██╔════╝██║██╔═══██╗
      ██║     ███████╗██║██║   ██║
      ██║     ╚════██║██║██║   ██║
      ███████╗███████║██║╚██████╔╝
      ╚══════╝╚══════╝╚═╝ ╚═════╝
   Brought to you by linuxserver.io
───────────────────────────────────────
To support LSIO projects visit:
https://www.linuxserver.io/donate/
───────────────────────────────────────
GID/UID
───────────────────────────────────────
User UID:    1000
User GID:    1000
───────────────────────────────────────
Linuxserver.io version: 4.6.5-r0-ls333
Build-date: 2024-05-30T01:46:36+00:00
───────────────────────────────────────
[custom-init] No custom files found, skipping...
WebUI will be started shortly after internal preparations. Please wait...
******** Information ********
To control qBittorrent, access the WebUI at: http://localhost:9080
Connection to localhost (::1) 9080 port [tcp/*] succeeded!
[ls.io-init] done.

Config File

### Config file

qBittorrent: 4.6.5
OS: Ubuntu 22.04
Libtorrent: 2.0.10.0
QT: 6.6.3
Docker: 26.1.3
Image: linuxserver/qbittorrent:4.6.5

### What is the problem?

Huge RAM consumption while downloading/uploading torrents until I get out of memory

### Steps to reproduce

[Application]
FileLogger\Age=1
FileLogger\AgeType=1
FileLogger\Backup=true
FileLogger\DeleteOld=true
FileLogger\Enabled=true
FileLogger\MaxSizeBytes=66560
FileLogger\Path=/config/qBittorrent/logs

[AutoRun]
enabled=false
program=

[BitTorrent]
Session\AlternativeGlobalDLSpeedLimit=0
Session\AlternativeGlobalUPSpeedLimit=71680
Session\AnonymousModeEnabled=true
Session\BandwidthSchedulerEnabled=true
Session\DHTEnabled=false
Session\DefaultSavePath=/downloads/
Session\DisableAutoTMMByDefault=false
Session\DiskCacheSize=512
Session\ExcludedFileNames=
Session\LSDEnabled=false
Session\MaxActiveDownloads=6
Session\MaxActiveTorrents=8
Session\MaxActiveUploads=5
Session\MaxConnections=2000
Session\MaxConnectionsPerTorrent=500
Session\MaxUploads=200
Session\MaxUploadsPerTorrent=50
Session\PeXEnabled=false
Session\Port=6881
Session\ProxyPeerConnections=true
Session\QueueingSystemEnabled=true
Session\TempPath=/downloads/incomplete/
Session\TorrentExportDirectory=/torrents
Session\UseAlternativeGlobalSpeedLimit=true

[Core]
AutoDeleteAddedTorrentFile=Never

[LegalNotice]
Accepted=true

[Meta]
MigrationVersion=6

[Network]
PortForwardingEnabled=false
Proxy\AuthEnabled=true
Proxy\HostnameLookupEnabled=true
Proxy\IP=amsterdam.nl.socks.nordhold.net
Proxy\Password=[REDACTED]
Proxy\Port=@Variant(\0\0\0\x85\x4\x38)
Proxy\Profiles\BitTorrent=true
Proxy\Profiles\Misc=true
Proxy\Profiles\RSS=true
Proxy\Type=None
Proxy\Username=[REDACTED]

[Preferences]
Connection\PortRangeMin=6881
Connection\UPnP=false
Downloads\SavePath=/downloads/
Downloads\TempPath=/downloads/incomplete/
General\Locale=en
MailNotification\req_auth=true
Scheduler\days=Weekday
Scheduler\end_time=@Variant(\0\0\0\xf\0\x36\xee\x80)
Scheduler\start_time=@Variant(\0\0\0\xf\x3\xdc\xc5\0)
WebUI\Address=*
WebUI\AuthSubnetWhitelist=192.168.1.0/24, 192.168.27.0/24
WebUI\AuthSubnetWhitelistEnabled=true
WebUI\LocalHostAuth=false
WebUI\Password_PBKDF2="@ByteArray([REDACTED]==:[REDACTED]==)"
WebUI\Port=9080
WebUI\ServerDomains=*
WebUI\Username=[REDACTED]

[RSS]
AutoDownloader\DownloadRepacks=true
AutoDownloader\SmartEpisodeFilter=s(\\d+)e(\\d+), (\\d+)x(\\d+), "(\\d{4}[.\\-]\\d{1,2}[.\\-]\\d{1,2})", "(\\d{1,2}[.\\-]\\d{1,2}[.\\-]\\d{4})"
Session\EnableProcessing=false
Copy link

github-actions bot commented Jun 4, 2024

Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.

@Roxedus
Copy link
Member

Roxedus commented Jun 4, 2024

How much is "high"?

@molotovah
Copy link
Author

How much is "high"?

Hi, it's using the whole container memory
qbittorrent

@Roxedus
Copy link
Member

Roxedus commented Jun 4, 2024

4 gb is not unreasonable for qbittorrent. Some instances idles at close to 4gbs, with lots of torrents to track.

@molotovah
Copy link
Author

It can increase to 8gb depending of the size of the file

@j0nnymoe
Copy link
Member

j0nnymoe commented Jun 4, 2024

How many torrents are you loading into this?

@j0nnymoe
Copy link
Member

j0nnymoe commented Jun 4, 2024

Also, try the libtorrentv1 tag

@molotovah
Copy link
Author

How many torrents are you loading into this?

2 seeding, 1 downloading

@newkind
Copy link

newkind commented Jul 13, 2024

I can confirm that somethings not right. I'm having the same issue on one of my NAS'es.

I'm using this image in 2 different NAS'es - old Synology DS713+ with old kernel 3.10.108 :
Linux DiskStation 3.10.108 #42962 SMP Mon May 29 14:36:28 CST 2023 x86_64 GNU/Linux synology_cedarview_713+
and a new Ugreen powered by UGOS Pro (based on Debian Bookworm):
Linux DXP6800PRO 6.1.27 #10 SMP PREEMPT_DYNAMIC Wed May 29 18:12:42 CST 2024 x86_64 GNU/Linux

On Synology with 4GB of ram docker shows container memory usage around 48MB (with 21 torrents active) and on the Ugreen with 16GB of memory its constantly sitting at 4GB of usage (as that's the limit set for the container). Doesn't matter if its running 2 or 10 torrents.

@LinuxServer-CI
Copy link
Contributor

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Issues
Development

No branches or pull requests

5 participants