zazu icon indicating copy to clipboard operation
zazu copied to clipboard

MEGA memory usage (over 8GB)

Open JulianKingman opened this issue 8 years ago • 12 comments

I installed and opened Zazu and found that only the calculator plugin was doing anything. Also it was acting quite sluggish. Upon inspection, it seems that zazu helpers were using over 8gb of memory (I only have 8gb). I assume this is temporary on account of indexing or something like that, but that's a lot of memory! Here's a screenshot.

screen shot 2017-01-04 at 7 46 37 am

JulianKingman avatar Jan 04 '17 12:01 JulianKingman

Yikes, that's a lot! I'm not seeing the same thing on my computer:

activity_monitor__all_processes__and_mega_memory_usage__over_8gb__ _issue__95_ _tinytacoteam_zazu

If you don't mind me asking, but can you try removing plugins one at a time to see if any of them are responsible for it? If I had to guess, my first instinct would be the file finder, as you suggested.

bayleedev avatar Jan 04 '17 14:01 bayleedev

Confirmed, it's the file finder.

Additional problems: quitting zazu doesn't quit the helpers, having the zazu dialog opens new 'high memory' zazu helpers (the original few zazu helpers don't exceed what you have shown).

JulianKingman avatar Jan 04 '17 15:01 JulianKingman

https://github.com/tinytacoteam/zazu-file-finder/blob/master/directories.js#L29

So it's currently going through:

  • /System/Library/PreferencePanes
  • ~/Applications
  • /Applications
  1. Do you happen to have a large number of files/directories in these folders?

  2. Also can you think of directories we could ignore that could help speed it up?

  3. Also, how big is the file /.zazu/plugins/tinytacoteam/zazu-file-finder/data/applications.json?

bayleedev avatar Jan 04 '17 16:01 bayleedev

  1. Not particularly. I have 150 apps or folders in the applications folder
  2. It's pretty barebones as it is. Quicksilver currently indexes and searches 19 directories, some nested 3 levels deep, and does OK.
  3. It doesn't exist...

JulianKingman avatar Jan 04 '17 18:01 JulianKingman

I just installed Zazu, and it made my mac's fans run like crazy. Checking the console did reveal that Zazu was eating up quite a bit of cpu. Things to note: this was my first time running Zazu, and I do have 305 items in my applications folder (none of which were showing up in the search). Also, only 1 item in ~/Applications and nothing in /System/Library/PreferencePanes. Immediately after quiting the application, my mac calmed down.

screen shot 2017-01-06 at 2 51 07 pm

jlarmstrongiv avatar Jan 06 '17 19:01 jlarmstrongiv

This is an issue with the file finder, it should be sped up and possibly broken up.

bayleedev avatar Jan 06 '17 21:01 bayleedev

Can confirm this; I had several instances of Zazu Helper open in the Activity Monitor, each using over a gig of memory, rendering my poor little Macbook Air basically unusable, haha.

junebash avatar Jan 12 '17 22:01 junebash

@jonbash can you also answer the questions in this comment:

https://github.com/tinytacoteam/zazu/issues/95#issuecomment-270413867

bayleedev avatar Jan 12 '17 22:01 bayleedev

I also have this issue. Right now it's using 3gb. I can't use Zazu if it does this. Have you ever seen the launcher Wox? They use the Everything software for doing file search, and the resource usage is not so excessive. Wonder if the same could be accomplished here. Though....I have no idea if it's available on other platforms, so that could be a problem.... also, it may not be temporary due to indexing, unless indexing takes 4+ days? I mean sure, I have a ton of files (6+ TB), but there are ways to index files that don't cause this kind of problem

SpaceOctopus avatar Sep 17 '17 23:09 SpaceOctopus

@SpaceOctopus yeah wox is a great suggestion.

The memory issue with the file finder has been fixed on Mac since it now uses the built in mdfind. It's also updated to allow other adapters.

bayleedev avatar Sep 20 '17 18:09 bayleedev

I just noticed Zazu (not the helpers) was using 2.8GB of RAM. Restarting it dropped it to 36MB.

OscarBarrett avatar Oct 27 '17 03:10 OscarBarrett

I'm running Zazu on ubuntu 16.04 LTS and I'm getting high numbers too but only when I leave the computer on overnight.

screenshot from 2018-02-16 10-50-18

chef-danny-d avatar Feb 16 '18 15:02 chef-danny-d