The first time I saw this error pop up on iTunes while trying to sync my iPhone, I had to restore my the device and lost all customizations. I had to start all over again, re-jailbroke the thing and loaded my apps.
iTunes cannot read the contents of the iPhone. Go to the summary tab in iPhone preferences and click restore to restore this iPhone to factory settings.
About a couple of months later, the same thing happened and I wasn’t ready for start all over again. I assumed there must be a way to fix this error and actually found it.
Why does this happen?
I don’t know much about iOS file system but from my observation, I can tell that this happens when the database that holds your iTunes information is corrupt. Two files are responsible for this: iTunesDB and iTunesCDB.
I’m not sure there’s a way to repair this files but like I mentioned before, there’s a fix for this that solves this error and you won’t need to restore your iPhone or iPad before you can sync
How do you fix it?
With the steps below, I can guarantee you should be able to sync your device without having to restore through iTunes. Even if your device isn’t jailbroken, you should still be able to do this.
1. Download and install iFunbox
2. Run the software and connect your iPhone
3. Click the iFunbox Classic tab
4. Select Raw File System from the left
5. Navigate to /private/var/mobile/Media/iTunes_Control/iTunes/
6. Delete both iTunesDB and iTunesCDB.
7. Safely remove your phone and close iFunbox.
You may now try to re-sync with iTunes.
Empty library and huge Other section
You may notice you have an empty library in your iPhone, iPad or iPod touch after performing the steps above and the Other section may be eating a lot of space. This is because your music files are still stored in your device’s file system, iTunes just can’t see them because there are no valid iTunesDB and iTunesCBD files.
Synchronizing again with iTunes should fix this but in case doesn’t help:
1. Connect your Apple device again, run iFunbox
2. Navigate to /private/var/mobile/Media/iTunes_Control/Music and delete all of the folders in the Music directory
3. You should do the same for the Artwork and Ringtones library too.
These should fix the huge Other folder shown on iTunes. You may now sync with iTunes and everything should work just fine.