Memory leak in Roon?! [Solved: Update to Build 970]

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.

@support how goes the war?

Hi @dylan

I’m also watching this with interest. I’m running Roon on Synology using the native app. I have the Deep Harmony and MQTT extensions installed.

Hi @dylan

I’ve noticed that over the last 6 hours since this morning the Roon memory requirement has increased by 0.3Gb despite having stopped the Deep Harmony extension. Looking forward to some positive news from you.

Hi @dylan (cc @danny )

It’s difficult to avoid the conclusion that you’re ignoring and avoiding responding to messages about this problem. Are you there? Can you please give some comfort to paying customers that this issue is being addressed please?

Last four days: just over 0.2Gb per day.

They’re working on it i think, but is probably a difficult problem.

1 Like

Hi, I suspect you’re right that they might be working on it, but it wouldn’t be difficult for them to confirm that and possibly even give some update. How long did it take you to reply? I do try and give folks the benefit of the doubt, particularly when I love their product, but patience can wear thin when I’m being ignored or stonewalled


Hi @John_Warden — I can confirm that this is something we are working on. The ticket is with our development team currently and it’ll need to be tested by QA after that, so these types of issues can definitely take some time. However, this remains a priority issue for us, and we’ll be sure to let everyone know when we have an update on this.

1 Like

Thanks @dylan for the response.

I appreciate these type of issues can take time and understand that you’ve all been under a lot of pressure recently. Perhaps you could keep us updated if it takes longer than you expect.

Hi Dylan,

I can also confirm this is an issue that I am currently experiencing on a fresh installed virtual machine running Ubuntu Server 20.04 (2 cores, 2 GB RAM).

The memory increases from around 700 MB to about 1700 MB in 5-7 days. A restart of the roon service helps it clear the memory again. Also I noticed that there are a lot of roon instances running on Linux at least, maybe other people can confirm?

Would be awesome if you guys are able to fix this!

1 Like

And after four days of normal usage the RAM is at almost maximum usage again.
Here you can see a list of when the RAM usage exceeded the configured threshold of 90% in Zabbix (monitoring software).

All my VM’s are running 180+ days without a reboot or me having to look after them every week, except Roon which is a bit annoying to be honest.

I might go ahead and configure a cronjob or something to restart Roon automatically every night as a temporary fix. Please let us know when there is a update regarding this incident!

Same issue on Ubuntu Server - I have to reboot every week as the memory usage slowly creeps up each day.
Like the idea above of a temporary cron job fix.

I am also on Ubuntu Server; my observation is that the problem gets worse with increasing library size. But there is no need to reboot the Ubuntu machine; just restart the roonserver service, this does the job.

sudo systemctl restart roonserver.service

1 Like

Only for Linux users:

Hi guys, I’ve setup my Roon service to reload every 2 days currently and thought you all might be interested in a simple and effective way to do this:

  1. Open the Roon systemd service configuration file with your favorite editor (On Ubuntu 18.04 / 20.04 usually /etc/systemd/system/roonserver.service)
  2. Add the following two lines under [service]:
    “Restart = always”
    “RuntimeMaxSec=86400” (Restarts every 24 hours from moment the service started.
  3. Write the config changes using your text editor
  4. Reload the system daemon with “systemctl daemon-reload”
  5. Congrats, if all went well your Roon should restart every 24 hours. Of course you can configure the above seconds to whatever you like, I have it at two days.

Example configuration of how it should look:

Still can’t quite wrap my head around why Roon uses that much memory, my VM was on less than 20MB after 6 days of uptime (of the available 2GB). Not sure what exactly the devs are doing, in what language they code or whatever but it’s clear that they’re not freeing memory properly. Clearly they haven’t heard of garbage collection…

Disclaimer: I haven’t taken backups in consideration here with the restarting, since I backup the entire VM every night. Not sure how these restarts might effect your Roon backups / database integrity. Use at your own risk and make proper backups!


Better just run this on cron so you can define the time and frequency.

Run as root:

sudo crontab -e

Restart the service every other night at 3am

0 3 */2 * * /bin/systemctl restart roonserver.service

This is a nice tool for the frequency: crontab guru


I backup to Dropbox every 4 days. Yesterday I did a forced backup and noticed 2 hours later that memory utilisation jumped by 16% and remained at that level. After restarting Roon server it returned to normal levels. This morning my scheduled backup excecuted and again memory usage jumped 16%. I have a QNAP NAS, 8GB, and core on a USB attached solid state drive. It seems like backups are causing issues with memory.

I have a huge library and suffer from memory leaks. I run Roon Core on an Ubuntu server running on a Proxmox server. I just re-rebuilt the server from scratch and reinstalled Roon from scratch and did not add any library files for a couple days. With a library of zero files my systems memory leak reached it’s limit of 16G in two days. Library size seems to have nothing to do with memory leak.

1 Like

Similar setup. I am using a vm of linux mint on proxmox. Linux mint has 4 Gb ram. I have 667 albums. If I restart the VM, Roon server already takes 1.7 Gb. After playing an hour it increases to 2.6 Gb. It is fairly stable but this morning client did not start up due to database corruption. So I had to reinstall. I try the nightly restart…

I cannot restart the roonserver.service. If I use ‘systemctl restart roonserver.service’ I get “Failed to add a watch for /run/systemd/ask-password: inotify watch limit reached” If I search what kind of inotify watches are consuming the system I see only some 30 RoonApplication watches. Any idea? I use 4 Gb ram.