1

New Macbook, I've turned off Spotlight indexing because it takes massive loads of processing power for ages. Also because I only use Command+Space for searching apps.

Spotlight off:

% sudo mdutil -sa
/:
    Indexing and searching disabled.
/System/Volumes/Data:
    Indexing and searching disabled.

Seems to override my settings on the Control Panel:

enter image description here

As expected, no Application shows up when I search for it (except for Firefox, which I've downloaded through Home-brew)

In the past I have tried enabling indexing only for /Applications but some other apps would still not show up, even if they're on such folder.

Anyone can tell me how to properly have all Applications show on Spotlight without having to turn indexing for the whole volume?

Thanks in advance.

5
  • 1
    Spotlight indexing should only use 'some' CPU resources for a short time; and then once it's done, it should keep fairly quiet, until perhaps the next OS update. I wouldn't disable it just because it's doing some work for a bit. At worst, you can let it run overnight.
    – benwiggy
    Apr 8 at 10:44
  • Spotlight panel controls what will appear in Spotlight results. It does not restrict indexing.
    – Gilby
    Apr 8 at 22:47
  • Thanks for the tips guys, but I would still like to know if I can enable Spotlight only for Applications and how to do it. Apr 9 at 1:23
  • Have you looked at app launchers, like Alfred or LaunchBar?
    – Gilby
    Apr 9 at 10:10
  • Hello @Gilby! Yes, but I would like to keep it stock. Spotlight does the trick as I only need to run apps from it, no documents nothing more. Apr 19 at 3:26

2 Answers 2

1

New answer (old answer got downvoted)

Answers the question:

Anyone can tell me how to properly have all Applications show on Spotlight without having to turn indexing for the whole volume?

The idea here is to have Spotlight index primarily Applications, which can be found in /Applications and /System/Applications, and not anything else.

The reason for indexing /System/Applications and not only /Applications is because when I did the following steps only for /Applications, native apps like Calculator or FaceTime did not show up, for reasons unknown to me.

/Applications is a firmlink and contains apps from both /System/Volumes/Data/Applications (user apps) and /System/Applications (native apps). More info here: Is there a difference between launching an app from /Applications vs /System/Volumes/Data/Applications?

To have Spotlight index mainly for Applications:

  1. Optional step, which verifies that Spotlight indexing stores have reduced in size (tremendously) after all steps are done.

    1. Go to "System Settings" -> "Privacy & Security" -> "Full Disk Access" -> toggle on "Terminal". This allows running commands on /System/Volumes/Data/.Spotlight-V100.
    2. Run sudo du -sh '/System/Volumes/Data/.Spotlight-V100' and you will get something like 435M /System/Volumes/Data/.Spotlight-V100, showing the current Spotlight indexing size.
  2. Go to "System Settings" -> "Siri & Spotlight" -> "Privacy" -> Add these folders to exclude them from being indexed:

    • /Library
    • /System/Library
    • /System/Volumes
    • /Users

    You will get a pop-up saying Are you sure you want to prevent Spotlight from searching in <folder>? for the folders /Library and /Users. Click OK to continue.

  3. If you did step #1, run sudo du -sh '/System/Volumes/Data/.Spotlight-V100' again and you will get something like 87M /System/Volumes/Data/.Spotlight-V100, showing the reduced size of the Spotlight index. Toggle off the Terminal option in Step #1.

Now, Spotlight's Command + Space works to show mainly Applications as the top hit. Also, the time it takes for the Apple system to re-index should be faster than what it was originally.

Old answer (still useful if anyone gets into indexing trouble)

You might need to reset your Spotlight indexing if it's acting up.

The following is what works for me:

  1. Go into your Spotlight panel and check the things you want to show up in Spotlight Search.
  2. Optional (at any point): mdutil -sav to display current indexing status on all volumes.
  3. sudo mdutil -i off -a to turn off / ensure indexing is turned off for all volumes.
  4. sudo mdutil -E -a to erase local indexing stores for all volumes.
  5. Restart computer.
  6. Once you login again, do sudo mdutil -i on -a to turn on indexing for all volumes.
  7. Open up Activity Monitor and leave the Mac on by itself to finish indexing. Indexing will be finished when you no longer see the large number of "mds_stores" or "mds" processes being run under the "Process Name" column, and the "CPU Load" graph has died down.
  8. Restart the computer a 2nd time.

Everything should be working as expected after these steps (well at least for me).

9
  • Thanks for your input but it has nothing to do with the problem I'm presenting. Apr 19 at 3:27
  • 1
    @mariano-daniel See my new answer, thanks for clarifying.
    – Aeronautix
    Apr 19 at 19:18
  • 1
    @mariano-daniel I believe my answer helps solve your problem, let me know if it did!
    – Aeronautix
    Apr 21 at 17:47
  • Perfection! Accepted as Answer. Thank you! :) Apr 24 at 21:32
  • But shouldn't mdutil -V /Applications -I on work better? Apr 24 at 21:38
0

I would turn Spotlight back on, reset it to its usual settings, then disable all of the other categories you chose in settings.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .