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] Very high memory usag 5.0.3 #363

Closed
1 task done
altendorfme opened this issue Jan 3, 2025 · 10 comments
Closed
1 task done

[BUG] Very high memory usag 5.0.3 #363

altendorfme opened this issue Jan 3, 2025 · 10 comments

Comments

@altendorfme
Copy link

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

I recently installed Bezel and noticed a very high memory usage by qBittorrent in version 5.0.3:

image

Expected Behavior

No response

Steps To Reproduce

  1. Run!

Environment

- OS: Debian 12

CPU architecture

x86-64

Docker creation

services:
  qbittorrent:
    container_name: qbittorrent
    image: ghcr.io/linuxserver/qbittorrent:latest
    ports:
      - 8085:8085
      - 6881:6881
      - 6881:6881/udp
    environment:
      - PUID=1000
      - PGID=1000
      - WEBUI_PORT=8085
    restart: always
    volumes:
      - /opt/qbittorrent:/config
      - /mnt/storage:/storage

Container logs

******** Information ********
To control qBittorrent, access the WebUI at: http://localhost:8085
Connection to localhost (::1) 8085 port [tcp/*] succeeded!
[ls.io-init] done.
Catching signal: SIGTERM
Exiting cleanly
[migrations] started
[migrations] no migrations found
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
───────────────────────────────────────
Linuxserver.io version: 5.0.3-r0-ls371
Build-date: 2025-01-01T22:48:48+00:00
───────────────────────────────────────

[custom-init] No custom files found, skipping...
WebUI will be started shortly after internal preparations. Please wait...
Copy link

github-actions bot commented Jan 3, 2025

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

@eduardlleshi
Copy link

I'm seeing the same thing. Memory jumped from ~30MB to 4GB. After a restart, it went back to 30ish MB. Now, it's rising again to the GBs. Not sure if it's a bug with latest release as I did not have any memory stats before.

CleanShot 2025-01-04 at 20 34 10@2x

@j0nnymoe
Copy link
Member

j0nnymoe commented Jan 4, 2025

You need to check if it's the actual qbittorrent process. Showing the container usage includes all processes within the container.

Also any sort of high memory usage is specific to qbittorrent and it's configured (or because of libtorrent2) and not the container.

@altendorfme
Copy link
Author

even in version 5.0.2, this problem continues, in the top I have this information:
image

@j0nnymoe
Copy link
Member

j0nnymoe commented Jan 4, 2025

As I mentioned in my previous comment, this isn't going to be container related. To be frank, memory usage in a torrent client is a massive variable as it depends on so many factors with what configuration you're running Vs how many torrents you have.

There just isn't a "oh disable this" I can say which will fix this.

@eduardlleshi
Copy link

My qBittorrent rarely has any torrents. 2-3 downloads a week.

Seems like the memory was freed by itself eventually today. Looking and it's history it did download a file before the memory started increasing, and based on some readings that's normal behavior.

@altendorfme Maybe we are overreacting because we're just noticing the memory with the new Beszel tool. I installed it yesterday and that's when I noticed it.

@altendorfme
Copy link
Author

altendorfme commented Jan 4, 2025

@eduardlleshi I've had Beszel for a while now and this problem started for me on day 1

I tested now version 5.0.1 and it seems more stable in this first hour:
image

There is a big thread about this at qbittorrent/qBittorrent#21502 :/

@altendorfme
Copy link
Author

5.0.1 also had problems, I did a rollback to 4.6.7 and it was resolved, I will follow the qbittorrent releases.

image

@nicolajkl
Copy link

I opened an issue over at the actual qbittorrent github and got an answer.
This is due to libtorrent 2.0 using memory mapped files.
Solution: set I/O mode to "simple pread/pwrite" in the advanced tab.

qbittorrent/qBittorrent#22099

@altendorfme
Copy link
Author

I opened an issue over at the actual qbittorrent github and got an answer. This is due to libtorrent 2.0 using memory mapped files. Solution: set I/O mode to "simple pread/pwrite" in the advanced tab.

qbittorrent/qBittorrent#22099

This seems to have worked really well!

image

@LinuxServer-CI LinuxServer-CI moved this from Issues to Done in Issue & PR Tracker Jan 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

No branches or pull requests

4 participants