How to stop Spotlight indexing

      Comments Off on How to stop Spotlight indexing

We clone the boot drive on our OS X servers for quick return from hardware or system failure. Spotlight indexing sees the clone once the process is done & indexes it…making 2 entries for everything. Here’s how to turn it off & remove the index entries. This works better than merely setting the “privacy” flag on the volume you don’t want indexed.

1. Let indexing begin on the volume.
2. Launch Terminal, which is in the Computer > Macintosh HD > Applications > Utilities folder.
3. At the prompt, type the following command, exactly as written:
sudo mdutil -i off /Volumes/volume_name
4. where volume_name is the name of the volume being indexed. [1]
5. Press Return.
6. If prompted for a Password, type your Admin password, then press Return. You will receive the response:
/Volumes/volume_name/: Indexing disabled for volume.
7. Spotlight will immediately cease to index the specified volume.
8. At the Terminal prompt, type the following command, exactly as written:
1. sudo mdutil -E /Volumes/volume_name
9. where volume_name is the name of the volume being indexed. [1]
10. Press Return.
11. If prompted for a Password, type your Admin password, then press Return. You will receive the response:
Volumes/volume_name/: Volume index removed.
12. At the Terminal prompt, type exit then press Return.
13. Quit (Command-Q) Terminal.

from The X-Lab

http://www.thexlab.com/faqs/stopspotlightindex.html