Ever tried to sync your iPod, iPhone or iPad to another iTunes library just to be presented with a messages saying that in order to sync, the device it has to be erased? iTunes makes it difficult to sync with multiple libraries, however in this tutorial I’ll show you a few different workarounds to successfully get iTunes to play by your rules and not erase everything.
One reason iTunes gives the error message telling you that you need to wipe the device in order to sync is because the persistent ID on the device could differ from the persistent ID on your computer. When a new iTunes library is set up, iTunes automatically generates a persistent ID, then transfers that persistent ID to the iOS device when you sync for the first time. Once the ID is setup on your Device it will only allow syncing to that one persistent ID, unless you have a jailbroken device then you can sync to as many libraries as you want. There used to be a way to change the persistent ID, however I believe Apple has patched/encrypted it now. Instead of changing the persistent ID we can just copy the iTunes Library.itl and iTunes Library.xml (where the persistent ID is stored) to a different iTunes library.
Before you do anything listed below I implore you to make a backup of your iTunes library or at least make a temporary copy of the iTunes Library.itl and iTunes Library.xml as a safe guard.
If you’ve downloaded some media into your iTunes library on one computer but use another computer to sync your iOS device, then save yourself the headache of trying to sync with the new iTunes library and just copy the media you’d like to sync to the computer you sync with. This can be done by copying the media itself onto a USB disk or other removable media solution and then dragging that content directly into iTunes on the computer you sync with.
If you have a jailbroken device all your need to do is install an App called MultiTunes from Cydia. Multitunes makes it incredibly easy to sync to multiple iTunes libraries. Just open Multitunes once installed and tap the “+” button, add a profile and then sync to any iTunes on any computer. To sync to multiple libraries, you need to create a new profile in MultiTunes for each iTunes library that you sync to. Oh, and to top it off, it’s free.
If you haven’t Jailbroken your device or are interesting in knowing how to Jailbreak, check out my other article: Jailbreak iOS 6 on iPhone 5, iPod, iPad 4 & mini
This works best in situations where you store the vast majority of media on one computer, however still want to be able to sync to your other computer. The most common situation in this case is, one computer has or is connected to a large hard drive with most of the media, and the other computer (usually a laptop) has a few albums or audiobooks ect, that you’d like to sync on the go. For this example lets say you have an iMac with a large 2TB drive and a laptop with only 250GB of space. You sync your iOS device on the iMac. Most if not all of the iTunes media is stored on the iMac. When you try to sync with the laptop iTunes tells you that in order to sync, everything has to be wiped of the device and then synced. This is because the persistent ID on the laptop is different from that of the iMac.
This method will delete the iTunes library data (not media files) on the laptop and replace it with the library data (including the persistent ID) from the iMac. If your laptop already has media it will have to be re-added to the iTunes library after these steps by simple dragging it back into iTunes. None of these steps will actually delete any of the media.
The first step is to plug your device into the iMac and navigate to the iPhone, iPod or iPads summary page. Under the “Options” make sure “Manually manage music and videos” is selected. The option, “Automatically sync when this [device here] is connected” has to be disabled.
Next, go to your iTunes media folder on the iMac, and copy the iTunes Library.itl and iTunes Library.xml into the iTunes folder on the laptop (make sure iTunes on the laptop is closed), overwriting the files that are currently there. This will copy the media structure as well as the persistent ID from the iMacs iTunes library to the laptops iTunes library. Since the persistent ID on both computers will be the same you can sync to both computers.
Now if you open iTunes on your laptop you’ll see an identical library structure of what’s on the iMac. Trying to play one of these files on your laptop will not work however since the actual media itself was not copied over. While in iTunes, go ahead and select everything from the Music, TV Shows, Movies ect, and delete it. When it asks you “Do you want to move the selected song [movie or tv show] to the Trash, or keep it in the iTunes Media folder?”, select keep it in the iTunes Media folder. This is just a safeguard to prevent accidentally deleting anything that could be in iTunes Media folder on your laptop.
Next step is simply go into the iTunes folder on the laptop and drag the “iTunes Media” folder into iTunes. It will grab every media file in there and set it all back up the way it was before. The play counts and ratings will not transfer over unfortunately as that information was stored in the itl and xml file that was overwritten. After everything is added back, go to the menu bar in iTunes -> Store -> Authorize this Computer.
Now when you plug your iOS device into either the laptop or iMac it will sync to both, just make sure that option to “Manually manage music and videos” is selected.
If you’ve just gone out and bought a new computer, or are just setting up a new iTunes library, then all that’s required is to copy the iTunes folder from your other computer to the new iTunes library. This can be done by coping the contents to an external drive (or other means) then plugging that drive into the new computer and copying the iTunes folder into your Music folder.
If iTunes has already been opened on your new computer there will already be an “iTunes” folder in your Music folder, simply copy & paste the iTunes library from your old computer to your new computer, overwriting if it asks you. This will copy over all the Music, Movies ect. It will also properly setup the artwork, persistent ID, ratings and any other meta data, creating an exact duplicate of the other iTunes to sync with.
If you just copy the media and not the library data files over to a new iTunes setup it will generate a new persistent ID which will make you wipe your iOS device in order to sync. So make sure you copy everything in the “iTunes” folder!
Restoring from backup is pretty much the same thing as setting up a new iTunes library. Just copy the “iTunes” folder back into the Music folder (or wherever you have iTunes set to store the media).
If you’ve lost your iTunes library and want to salvage all the media you have on your device, and then add it back to iTunes you need to copy the media off your device to your computer then add it back to iTunes.
Unfortunately, since the iTunes library was lost, once you try to sync with new iTunes library it will make you wipe the iPod, iPhone or iPad as the persistent ID will be different. However once the device is wiped it will sync back all the content you copied off your device into iTunes. Make a backup in iTunes or iCloud first.
I really wish Apple would make it simpler to sync to multiple computers, it’s like they don’t want us to share media or something. No, but seriously, it really should be simpler to sync to multiple computers. Before I had a Mac, I had the entirety on my media stored in iTunes on my PC. I transferred all my media from the PC to my Mac the plugged my iPhone in thinking, “Hey, I’ve authorized this computer with my Apple ID so it should sync”.
Took me about a minute to figure out that I should have read the message iTunes showed saying that I had to erase my device to sync, instead of hastily clicking on the “Erase” button. Another importance of backing up your device.
I’ve spent a good 4-5 hours attempting to change the persistent ID. I’ve edited the persistent ID, locked the file so iTunes can’t change or modify it, edited the .itl file with a Hex editor, even created a new partition with Windows and tried changing it there. I’ve had no luck changing the persistent ID whatsoever. It may have worked in the past with older versions of iTunes however with the newer versions of iTunes I simply do not think it is possible.
For those interested in finding the persistent ID, just go to your iTunes folder and located the iTunes Library.xml file. Open the xml file with any basic text or word editor. Look a little ways down the list until your find the “Library Persistent ID”.
<key>Library Persistent ID</key><string>01A08C21CF4369F4</string>
The mess of numbers and letters is your ID, mine is “01A08C21CF4369F4” yours will be different.