Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the '10.4: Force Spotlight to reindex a drive' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.4: Force Spotlight to reindex a drive
Authored by: danielj7 on Apr 29, '05 10:32:58PM

You can also do this from the command line with the mdutil command. Launch Terminal and enter:

sudo mdutil -E /

and the index file will be erased and rebuilt. The "/" stands for the boot volume; you can substitute the pathname of any volume here.

Substitute "-s" for "-E" to show if indexing is enabled on the volume, and "-i on" or "-i off" to enable or disable indexing. Note that mdutil must be run as root; hence the sudo.

You can also use mdimport to index a subset of files:

mdimport ~/Documents

would index your Documents folder and

mdimport -r /Library/Spotlight/AppleWorks.mdimporter

would index all AppleWorks files on your computer.

mdimport -L

will list all installed metadata importers.



[ Reply to This | # ]
10.4: Force Spotlight to reindex a drive
Authored by: fuzzy_logic on Apr 29, '05 11:53:38PM

For some reason, Spotlight doesn't work on my System Preferences. No matter what I type in, everything dims. Anyone has a solution to this?
Thanks in advance!



[ Reply to This | # ]
10.4: Force Spotlight to reindex a drive
Authored by: skunk on Apr 30, '05 10:51:23AM

Thanks for the info on forcing Spotlight to re-index, but it STILL can't find lots of stuff on my hard drive, both folders and files.



[ Reply to This | # ]
10.4: Force Spotlight to reindex a drive
Authored by: claviclaws on Apr 30, '05 12:17:01PM

Also useful is the -f flag: I keep all my music on my iPod; Apple (probably in an attempt satisfy the RIAA etc etc etc) hasn't allowed Spotlight to index your iPod's music (although all other files on the iPod are indexed), even when specifying the correct directory. Fortunately the 'force' flag bypasses this inconvenience:

$ sudo mdimport -f /Volumes/your_iPod/iPod_Control/

for indexed music goodness.



[ Reply to This | # ]
10.4: Force Spotlight to reindex a drive
Authored by: timstringer on May 01, '05 10:43:25AM

I was having a similar problem where much of my content wasn't showing up through Spotlight. So, I entered the "sudo mdutil -E /" command as suggested. Spotlight immediately when through a reindex process that took approximately an hour to complete. But, once it was done, I discovered that none of my imported mail could be accessed (the messages appear to still be there, but they don't show up under the Mail application).

Any suggestions are most welcome. Thanks!



[ Reply to This | # ]
10.4: Force Spotlight to reindex a drive
Authored by: geohar on May 02, '05 05:01:09AM

Try

mdimport ~/Library/Mail/*/*.mbox/Messages

Good luck



[ Reply to This | # ]