Nyx memory leak

When I use the nyx monitor in gateway, my ram usage get bigger and bigger until gateway freeze

xfce 16.0.8.2
nyx 2.1.0 jan 12, 2019

Generic Bug Reproduction required.

Some discussion on memory leak of nyx on GitHub

Can reproduce a memory leak of nyx on Whonix-Gatway (version 17). Tor version 0.4.7.16, nyx 2.1.0-2.2 and stem 1.8.1 (all versions included with Whonix-Gateway).

To reproduce: Have nyx running on Whonix-Gateway and on Whonix-Workstation open many links in Tor Browser across separate domains to generate many streams (The various links on the Whonix welcome page are good for this) and observe memory usage ballooning. Notice how even when Tor Browser is closed and Whonix-Workstation is shut down the memory usage of nyx does not go down.

Unfortunately nyx is unmaintained upstream so distribution of any improvements to it would have to be coordinated by the Whonix project if desired.

Thank you.

I don’t plan on software forking nyx. If someone wants to contribute to nyx, please work with the The Tor Project.

Quote atagar from Needs more than two gigabyte RAM if running for two days · Issue #52 · torproject/nyx · GitHub

I’m the author of both Stem and Nyx. I left Tor a couple years ago whereupon Georg (gk at torproject dot org) took over but he doesn’t monitor GitHub. You’ll need to email him if you’d like to get his attention (see this issue for the latest discussion on that). You can also try tor-dev@.

Try this if you want to see this fixed.

This was not a final plan or demand for action. Just some thinking for the issue.

If the upstream Tor project is willing to collaborate towards either investigating or maintaining a solution that would be ideal.

Next challenge is to investigate the memory leak itself and what would be needed to fix it. Some investigation has been conducted in the above linked GitHub issue but is not conclusive. For example the version of stem included with Whonix-Gateway and was used for my test is 1.8.1 while there has been another relase since them.

Thank yo

Whonix ships the version that comes from packages.debian.org. Related: Operating System Software and Updates chapter Frozen Packages in Kicksecure wiki
(Whonix is based on Kicksecure.)

My current thinking at this stage is to reproduce this memory leak with latest nyx and stem from upstream to remove potential variables under question. If the root cause (and potential solution) can be identified that would be best. From there perhaps current Tor developers could be engaged in this discussion.

Thank you.