When you move music files around, iTunes loses track of their location and their playlist entries become “dead”. You get broken file icon and iTunes embarrassing itself with primitive workaround:
Locating files manually is sooo 20th century…
Why would you have to locate the file, if your computer has excellent search — Spotlight — available at its fingertips? Wonder no more. iTunesFixer uses Spotlight to find all tracks that iTunes has lost.
Download iTunes Fixer for Mac OS X Leopard
The program will work only if you still have the music files on your disk and they are indexed with Spotlight. It will not work if you have music on network drive that Spotlight doesn't search.
Tracks are matched by file name and file size. If you have modified (e.g. converted) music files after iTunes lost them, iTunes Fixer won't be able to find them. It cannot find files that have been renamed.
It may not be able to fix all playlist entries. It will leave them untouched, so don't be surprised if you run iTunes Fixer multiple times and it will try (and fail) to fix same files again and again.
iTunes Fixer doesn't delete anything and double-checks that it changes correct playlist entries, but just in case you wanted to be 100% safe, you can back up your iTunes Library:
iTunes Library Extras.itdband
iTunes Music Library.xmlfiles.
porneL. You may bug me on Twitter.
Source code is available under BSD license.
This little application touches surprisingly large number of cool OS X technologies:
iTunes Music Library.xmlplist file.
NSOperationqueues (presumably backed by Grand Central Dispatch in Snow Leopard)
That last bit (and evenly progressing progressbar) was by far the hardest thing to implement!