Services slowly eating up RAM

chri5

Explorer
Joined
Apr 8, 2022
Messages
76
My services are slowly eating up more and more ram. After a reboot I usually have over 16gb ram free (32 total). But as the days go by my services slowly eat up ram despite me not adding to or changing the existing services. Is this usual?

I should add I'm using, plex, nextcloud & traefik. 1 VM running ubuntu server with nginx, and a samba share.
 
Last edited:

LarsR

Guru
Joined
Oct 23, 2020
Messages
719
Have you installed any apps or truecharts as an additional repository?
Right now the catalogue sync data is stored in ram and counts to system memory. It's syncing the previous and the current catalogue data.
That could be 1-2gb of data for each sync when truecharts is added.
If you don't have any apps installed it could be a memory leak.
 

chri5

Explorer
Joined
Apr 8, 2022
Messages
76
Have you installed any apps or truecharts as an additional repository?
Right now the catalogue sync data is stored in ram and counts to system memory. It's syncing the previous and the current catalogue data.
That could be 1-2gb of data for each sync when truecharts is added.
If you don't have any apps installed it could be a memory leak.
Just Traefik and nextcloud from the truecharts core repo. Plex is from the official repo.
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,703

bomg

Dabbler
Joined
May 10, 2022
Messages
10
@chri5, you might be interested in this thread discussing memory bloat issues related to the app catalog (pages 1-2) and to keeping the web dashboard open (pages 2-3).
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
SMB counts in services and it does do caching of its own, so can grow in memory use over time.
There is limit to how large smbd process should grow. Memory usage will be visible in `top` and `ps` output and associated process will be `smbd`.
 
Last edited:

MountainMan

Dabbler
Joined
Dec 10, 2020
Messages
42
This is a frustrating issue. I *feel* like there there are multiple issues at play here with middlewared -- which has a variety of responsibilities it seems. I see it's memory footprint endlessly grow, and CPU use bumping up over time after some yet-unknown event(s).

In looking with pmap, the anon memory blocks endlessly increase and become the vast majority of the memory by middlewared for me over time. I made a script to track that over time which I've just started up. Plan on rebooting, not using the UI at all for a day, then leave a browser on the dashboard for a day, normal use for a day, etc. Horrible way to try and identify things, but the tickets in JIRA seem pretty stalled.

Just seems odd more people don't seem to experience it, as I have a pretty simple configuration with just a few pools, SMB, and one official app (Plex) running.
 

Trevor68

Contributor
Joined
Oct 15, 2021
Messages
130
I too have a quite simple setup and only 6 apps running. When I started with SCALE at the RC point I could go a month easy without using up all the RAM. Now it's about a week.
 

Trevor68

Contributor
Joined
Oct 15, 2021
Messages
130
Ok, it looks like I lose a chunk of RAM at 10pm every night? How would I track that down?
 

Attachments

  • 2022-05-28.png
    2022-05-28.png
    253.9 KB · Views: 259

asc72

Dabbler
Joined
Mar 19, 2017
Messages
13
I am seeing the same issue. Services continue to grow until I restart the server. I have 5 apps installed, no VMs.

1654193203894.png
 

bacardi8

Explorer
Joined
Oct 19, 2021
Messages
85
Same here.
Plex and Emby is the only apps that I have installed.
Before I never see that, so maybe since the latest update this is happening..??

Until now I just restart if I want to bring it down to normal again, but for now I will try to let it run,
just to see how high it goes.

A question here is, will it go higher than 50%, and will it automatically drop/free up Ram, if these are needed for other tasks...???
this would then actually be normal behavior as far as I know.
 

Botched1

Cadet
Joined
Apr 10, 2022
Messages
4
Same here. I know that doesn't help, in and of itself.

On reboot services use ~5GB on my system.
After 25 days uptime they were up to 23GB.

Just reboot, now back to 5GB.

I wouldn't be surprised by SOME increase over time as I am running 1 VM (2GB ram allocated) and 1 container. But 5GB to 20+GB seems like a lot.

Memory Graph - I don't see one that specifically shows "services":
1654266391742.png
 
Last edited:

Trevor68

Contributor
Joined
Oct 15, 2021
Messages
130
Mine grows like clockwork at 9pm everyday, guess I will need to track down what it's doing at that time somehow.
 

Trevor68

Contributor
Joined
Oct 15, 2021
Messages
130
I see a "User" CPU spike and corresponding drop in free RAM at 9PM each night, I have no system scheduled tasks, so either the Truecharts Catalog is updating then, or one of my apps are.
 

pabloalcantara

Dabbler
Joined
Feb 21, 2022
Messages
29
Probably is some kind of middleared memory leak.
I have created a "solution", it´s not the best o elegant, but it´s working.
I have created a simple script that runs "systemctl restart middlewared" every 2 days.
 

chri5

Explorer
Joined
Apr 8, 2022
Messages
76
memory-usage.PNG

After each reboot you can see free memory decline and used increase.
 
Top