Huge RAM leakage leading to a system crash + high CPU consumption.

Discussion related to "Everything" 1.5 Alpha.
Post Reply
Turok
Posts: 9
Joined: Fri Nov 22, 2024 12:26 pm

Huge RAM leakage leading to a system crash + high CPU consumption.

Post by Turok »

Hello,
First I'd like to thank the creator of such an awesome program, I really love it and couldn't live without it. A million thanks for keeping updating it and adding key features like sessions, which helped me a lot :D

Now the problem I'm facing is that over time Everything decides to eat all my ram and fill up the pagefile as well until my system crashes.
I don't understand its behaviour because yes, I have dozens of tabs opened at the same time, but without opening more or even interacting at all with the program for a while, the program starts to consume more and more ram, from 15-30gb (it increases over time, but slowly for a while) to all of it and even a lot from a pagefile of more than 100GB (specially huge for Everything to last longer before making the system crash).

I don't know if it eats all of the available pagefile or just an enough amount to make the system unable to handle it and lead to a crash. Honestly, I don't know if this is possible. What I've seen is that when the free ram is close or lower than 1GB and I check the pagefile usage, the amount in use is about a 40-50% of the total available. But then I quit from Everything, so I don't know how much it ends consuming until the crash happens. After closing Everything up to 40GB of ram are recovered. Then restoring the previous session leaves the system with around 20-25GB of free ram. It keeps using a similar amount for a few hours, until suddenly the above mentioned happens, and if I'm not paying attention it ends up in the system crashing due to the system getting out of ram.

It has also a CPU usage of more than a 15%, is this normal?
I'm sitting on a 64GB system and without Everything running the normal consumption can reach around 30GB due to other programs running.
DB size is only 1.5GB.

To add just something I've noticed is that the only property I have set (lenght) takes a lot to get updated, and it does it in bulks, not in real time as new files are stored but in a long process at a certain moment. I think in that process it consumes more ram. Is this the expected behaviour? any way to make it update that attribute in real time?

Screenshot taken short after starting Everything. I'll add others later as it keeps using more resources.
image.png
image.png (8.71 KiB) Viewed 317 times
Last edited by void on Fri Nov 22, 2024 10:39 pm, edited 2 times in total.
Reason: fixed image
therube
Posts: 4985
Joined: Thu Sep 03, 2009 6:48 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by therube »

None of what you say is "normal".

Your screenshot (since it doesn't show up), https://ibb.co/6v4pHRq.
(That's a lot of RAM ;-).)

What version of Everything? [1.5.x ?]
How many files are we dealing with?
Aside from indexing just these files, are you also indexing any file Properties (if using 1.5)? [Length]
Post, Help | Troubleshooting Information.
Turok
Posts: 9
Joined: Fri Nov 22, 2024 12:26 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by Turok »

Version 1.5.0.1383a (x64)
The total amount is around 25M, mostly are empty folders (I need to keep this folders tree). Time ago the total amount reached more than 100M (99% empty folders) and I had not this issue. It indeed used to use a lot of ram, but I don't remember it eating all the free RAM + Pagefile until making the system crash. I had then a 15-30GB .db, but it used to take a lot of time at each start for the program to be usable.
About the properties, only Length is being indexed.
Thank you for fixing the image ;)

Now my index settings looks like this:
Image

At some point I'd like to recover the +100M tree folder structure but I'm scared it won't be possible not even doubling the RAM if the Everything's voracity persists :lol:
void
Developer
Posts: 16770
Joined: Fri Oct 16, 2009 11:31 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by void »

Are you indexing content?

Please try disabling content indexing under Tools -> Options -> Content.
Turok
Posts: 9
Joined: Fri Nov 22, 2024 12:26 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by Turok »

Nope, that option is already disabled.
Turok
Posts: 9
Joined: Fri Nov 22, 2024 12:26 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by Turok »

Turok wrote: Fri Nov 22, 2024 11:33 pm Version 1.5.0.1383a (x64)
The total amount is around 25M, mostly are empty folders (I need to keep this folders tree). Time ago the total amount reached more than 100M (99% empty folders) and I had not this issue. It indeed used to use a lot of ram, but I don't remember it eating all the free RAM + Pagefile until making the system crash. I had then a 15-30GB .db, but it used to take a lot of time at each start for the program to be usable.
About the properties, only Length is being indexed.
Thank you for fixing the image ;)

Now my index settings looks like this:
Image

At some point I'd like to recover the +100M tree folder structure but I'm scared it won't be possible not even doubling the RAM if the Everything's voracity persists :lol:
I've been thinking and indeed when I had +100M folders sometimes the program was using a lot of ram + pagefile, just to free it up both after a while. Sometimes closing some other apps first, I don't remember if just to speed up the process or as a requirement for it to happen. I used to do this because how slow was to get the program ready after closing it. Now it's almost instant so I can restart it when I notice the leakage. The problem is when I don't notice it. Many times I leave the PC unattended for 10-20 minutes, I come back just to find the system has crashed. Checking the events viewer it says the system got out of virtual/memory.
void
Developer
Posts: 16770
Joined: Fri Oct 16, 2009 11:31 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by void »

Please send your Help -> Troubleshooting Information in a bugreport

For 100 million folders, I would expect Everything to use around 10GB of RAM.
Turok
Posts: 9
Joined: Fri Nov 22, 2024 12:26 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by Turok »

void wrote: Sat Nov 23, 2024 12:28 am Please send your Help -> Troubleshooting Information in a bugreport

For 100 million folders, I would expect Everything to use around 10GB of RAM.
:shock:
Impressive, there is hope then.

I'll do it right away.
void
Developer
Posts: 16770
Joined: Fri Oct 16, 2009 11:31 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by void »

Thanks for the Help -> Troubleshooting Information.

Your setup looks OK.
request_extra_fileinfo_end=2000
This setting could be causing trouble.
This will prefetch 2000 thumbnails.

To change this setting:
  • In Everything 1.5, from the Tools menu, click Options.
  • Click the Advanced tab on the left.
  • To the right of Show settings containing, search for:
    extra
  • Select: request_extra_fileinfo_end
  • Set the value to: 0
    (0 is the default)
  • Click OK.
See if the issue persists when this is set to: 0

request_extra_fileinfo_end



Please try lowering your thumbnail size:
  • In Everything 1.5, from the Tools menu, click Options.
  • Click the Advanced tab on the left.
  • To the right of Show settings containing, search for:
    thumbnail
  • Select: thumbnail_load_size
  • Set the value to: 64
  • Click OK.


Could you please send your Tools -> Debug -> Statistics in a bugreport
Turok
Posts: 9
Joined: Fri Nov 22, 2024 12:26 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by Turok »

void wrote: Sat Nov 23, 2024 1:13 am Thanks for the Help -> Troubleshooting Information.

Your setup looks OK.
request_extra_fileinfo_end=2000
This setting could be causing trouble.
This will prefetch 2000 thumbnails.

To change this setting:
  • In Everything 1.5, from the Tools menu, click Options.
  • Click the Advanced tab on the left.
  • To the right of Show settings containing, search for:
    extra
  • Select: request_extra_fileinfo_end
  • Set the value to: 0
    (0 is the default)
  • Click OK.
See if the issue persists when this is set to: 0

request_extra_fileinfo_end



Please try lowering your thumbnail size:
  • In Everything 1.5, from the Tools menu, click Options.
  • Click the Advanced tab on the left.
  • To the right of Show settings containing, search for:
    thumbnail
  • Select: thumbnail_load_size
  • Set the value to: 64
  • Click OK.


Could you please send your Tools -> Debug -> Statistics in a bugreport
Hello, I've been testing this workaround, and it seemed very promising for a few hours. It was using only 5-6gb of ram most of the time, with some spikes to 10 and a few times to 25, but going down short after. Then, after a while, I noticed this:
image.png
image.png (6 KiB) Viewed 59 times
:shock:

Never seen such an high amount of ram being used by a process nor by adding them all up. Actually I thought that this value in Process Hacker was only ram, but my system has 64gb, so I must assume it also takes into account the virtual memory? weird.
Since then the program keeps using similar values to those wrote in my first paragraph most of the time, so it's an improvement, but time to time it still reaches an high usage (26, 38, 45) that leaves me with 1-2GB free and the program needs a restart. This, again, not even interacting with Everything or having done any new search (beyond those already in place after restoring the session) since the last restart. So if there is any other tweak I could try I'd be glad to hear.
Actually I wonder, as I mentioned I have dozens of tabs with their respective searches, and I restore this session on every restart. My logic is that the RAM consumption should stay stable with this method after the session is restored. But is this really the expected behavior? or may this be causing those increases in RAM usage as time goes by?

Your help is very appreciated :)
I'll send the statistics log in a while.
therube
Posts: 4985
Joined: Thu Sep 03, 2009 6:48 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by therube »

Again, as your image is not displaying, https://imgur.com/EBI8zVz.
(I didn't see where imgur allows hotlinking?)
void
Developer
Posts: 16770
Joined: Fri Oct 16, 2009 11:31 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by void »

Are you showing thumbnails?
-Does the issue only persist when viewing thumbnails?
You might have a bad third party thumbnail handler..
Turok
Posts: 9
Joined: Fri Nov 22, 2024 12:26 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by Turok »

therube wrote: Tue Nov 26, 2024 3:36 pm Again, as your image is not displaying, https://imgur.com/EBI8zVz.
(I didn't see where imgur allows hotlinking?)
I don't know about hotlinking, sorry. I thought it wasn't being showed due to the host I used in my first post, so I swapped to IMGUR for my second and it worked there. Got it, I must use the raw link. Thank you for fixing it.
Turok
Posts: 9
Joined: Fri Nov 22, 2024 12:26 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by Turok »

void wrote: Tue Nov 26, 2024 11:54 pm Are you showing thumbnails?
-Does the issue only persist when viewing thumbnails?
You might have a bad third party thumbnail handler..
You're right! I use Icaros. I have been using it for quite a few years now, since I suffered a bug with the thumbnails not being displayed or something similar, and never had a problem again.
"-Does the issue only persist when viewing thumbnails?"
Well, from the many tabs I have opened yes, many of them are showed as thumbnails.
So do you think this is causing the RAM leakage? would you be so kind to explain why, if it's a conflict or? No need for a detailed explanation, just a summarize, I'd just like to understand.
And what should I do then, uninstall Icaros? or is there some setting in Everything I can tweak to make it work better?

PS: Just noticed that Icaros it must be outdated, never worried about as it was fulfilling its purpose. I'll update it and check if it fixes this problem.
void
Developer
Posts: 16770
Joined: Fri Oct 16, 2009 11:31 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by void »

So do you think this is causing the RAM leakage?
It's possible thumbnails are causing the issue.

A thumbnail handler is most likely the cause if you can't reproduce the issue without showing thumbnails.


And what should I do then, uninstall Icaros? or is there some setting in Everything I can tweak to make it work better?
Some ideas:

Use a smaller thumbnail load size:
  • In Everything 1.5, from the Tools menu, click Options.
  • Click the Advanced tab on the left.
  • To the right of Show settings containing, search for:
    thumbnail
  • Select: thumbnail_load_size
  • Set the value to: 64
    (where 64 is the desired thumbnail size in logical pixels)
  • Click OK.


Limit thumbnails to the desired file extensions only:
  • In Everything 1.5, from the Tools menu, click Options.
  • Click the Advanced tab on the left.
  • To the right of Show settings containing, search for:
    thumbnail
  • Select: thumbnail_include_only_files
  • Set the value to: *.png;*.jpg
    (where *.png;*.jpg is the semicolon (;) list of desired extensions)
  • Click OK.
Turok
Posts: 9
Joined: Fri Nov 22, 2024 12:26 pm

Re: Huge RAM leakage leading to a system crash + high CPU consumption.

Post by Turok »

void wrote: Wed Nov 27, 2024 5:50 am
So do you think this is causing the RAM leakage?
It's possible thumbnails are causing the issue.

A thumbnail handler is most likely the cause if you can't reproduce the issue without showing thumbnails.


And what should I do then, uninstall Icaros? or is there some setting in Everything I can tweak to make it work better?
Some ideas:

Use a smaller thumbnail load size:
  • In Everything 1.5, from the Tools menu, click Options.
  • Click the Advanced tab on the left.
  • To the right of Show settings containing, search for:
    thumbnail
  • Select: thumbnail_load_size
  • Set the value to: 64
    (where 64 is the desired thumbnail size in logical pixels)
  • Click OK.


Limit thumbnails to the desired file extensions only:
  • In Everything 1.5, from the Tools menu, click Options.
  • Click the Advanced tab on the left.
  • To the right of Show settings containing, search for:
    thumbnail
  • Select: thumbnail_include_only_files
  • Set the value to: *.png;*.jpg
    (where *.png;*.jpg is the semicolon (;) list of desired extensions)
  • Click OK.
Ok, thank you for your advice, it's amazing to see such a nice technical support for an app that you bring us for free ;)
If after updating Icaros the problem isn't solved I'll try those workarounds and I will come back to present the results.
Post Reply