Really Disable the Spotlight Menu

A few months back I found a nice tip.1 While this had the desired effect (I didn't have to waste menubar space on that monstrosity, the next time I looked in the console, I saw hundreds of messages like this:

1/8/09 1:05:28 PM com.apple.launchd[135] (com.apple.Spotlight[79745]) posix_spawnp("/System/Library/CoreServices/Spotlight.app/Contents/MacOS/Spotlight", ...): No such file or directory 
1/8/09 1:05:28 PM com.apple.launchd[135] (com.apple.Spotlight[79743]) Exited with exit code: 1 
1/8/09 1:05:28 PM com.apple.launchd[135] (com.apple.Spotlight) Throttling respawn: Will start in 10 seconds 

What this tells s is that launchd has been instructed to not just start Spotlight, but also to keep it running. So, once to make Spotlight impossible to run, launchd will keep trying again, every 10 seconds. The solution is to tell it that it needn't bother:

sudo launchctl unload -w /System/Library/LaunchAgents/com.apple.Spotlight.plist

This command will have spotlight remove the launch agent which tells it to run SPotlight from its to-do list, and furthermore modify that launch agent to no longer be used in the future (like after you restart your system).

EDIT: You can reverse the effects of the launchctl command by replacing the 'unload' with 'load':

sudo launchctl load -w /System/Library/LaunchAgents/com.apple.Spotlight.plist

  1. Note that in the comments to the tip above, someone else gives and alternate method for doing the same thing that I suggest here. I think that my way is more elegant, as it actually mends launchd's instructions, rather than (as best I can tell) blocking it from reading the launch agent by brute force. 

No Comments

Comment on this post