Originally from: http://support.apple.com/kb/HT1451
Learn what to do if you don’t see all of your songs, albums, playlists, or other imported content after you update iTunes on your computer.
iTunes keeps track of your content and playlist in a library file. If iTunes can’t update your library file immediately after an iTunes update, you might notice missing imported content and playlists. Learn how to restore your iTunes library.
If you’re missing content or playlists and didn’t recently update iTunes, get more help:
Learn what to do if you see an exclamation mark next to music in iTunes.
Restore your iTunes library
Before following the steps below, make sure that you have the latest version of iTunes.
- Quit iTunes.
- Go to the iTunes folder that contains the iTunes library files:
Mac: From the menu bar at the top of your computer screen, choose Go > Home. Open the Music folder, then open the iTunes folder.
Windows: Navigate to \Users\username\Music\iTunes\
- Drag the iTunes Library.itl file to your Desktop. Learn what to do if you can’t find the file.
- In the iTunes folder, open the Previous iTunes Libraries folder.
- Find the file named iTunes Library YYYY-MM-DD where YYYY-MM-DD is the date you updated iTunes (Year-Month-Day).
If you don’t see a Previous iTunes Libraries or a recent YYYY-MM-DD file, your iTunes Library file might be in a custom location. Search for Previous iTunes Libraries on your computer to find the most recent YYYY-MM-DD, then continue with step 6.
- Select the file, then press Cmd + C (Mac) or Ctrl + C (Windows).
- Press Cmd + Up arrow (Mac) or Alt + Up arrow (Windows).
- Press Cmd + V (Mac) or Ctrl + V (Windows).
- The YYYY-MM-DD file should now be copied into your iTunes folder. Rename the copy “iTunes Library.itl” (without the quotation marks).
- Hold down the Option key (Mac) or the Shift key (Windows) and open iTunes.
- When you see a message that asks you to Choose iTunes Library, click Choose Library. Point iTunes to the file you renamed in step 9.
Your iTunes Library should now be restored. If you see all your content and playlists in iTunes as expected, you can move the iTunes Library.itl file on your Desktop to the Trash.
Any changes that you made to your library after the date on the iTunes Library that you used in step 5, such as new playlists that you created or songs that you added, might not appear in iTunes and might need to be recreated or re-added.