Opened 9 months ago

Last modified 3 months ago

#3423 pending bug

Memory Leak on Linux

Reported by: cinderblock Owned by:
Priority: major Milestone: not applicable
Component: libtorrent Version: 2.0.3
Keywords: Cc:


I've been running Deluged 2.0.3 on my server for a while now. I have nearly 500 torrents seeding but only a few active at a time. It's mostly stable, except every ~month I take a look and it's using 100% of available memory (32GB) and CPU.

Restarting the service brings the memory usage back down to ~400MB. However it starts growing pretty quickly. I restarted my current instance a day or two ago and it's currently using nearly 5GB. I just did a quick test and looked at the RSS memory usage across a 10 minute interval. It seems to be growing at 182 kBps. (At this rate it should only take 2 days to fill all 32GB! So clearly this 10min sample doesn't capture the whole picture...)

I have a nearly identical instance of Deluged running on the same machine for a separate network. It only runs ~50 torrents and never seems to have these memory leak problems.

Change History (5)

comment:1 Changed 9 months ago by cinderblock

I think this is actually a duplicate of #3327. I found some logs spewing out many "Unhandled error in Deferred"s that match what is described there.

comment:2 Changed 8 months ago by Alexey104

This is the libtorrent issue which was finally fixed in 1.2.10:

comment:3 Changed 8 months ago by cinderblock

Glad to hear. What's it going to take for this to be incorporated to Deluge? Should I be able to update to latest libtorrent, reinstall deluge python3 bindings, and have it work?

comment:4 Changed 8 months ago by Alexey104

Yes, just compile libtorrent with python bindings using the latest commit from the 1.2(not 2.0!) branch(if your distro doesn't already provide it in the official repos), and it should solve your problem. I had been experiencing exactly the same issue that you describe, and 1.2.10 completely solved it for me.

Last edited 8 months ago by Alexey104 (previous) (diff)

comment:5 Changed 3 months ago by Cas

  • Component changed from Core to libtorrent
  • Milestone changed from needs verified to not applicable
  • Status changed from new to pending
Note: See TracTickets for help on using tickets.