How To:  Change iTunes media library location/folder

*PLEASE READ THIS ENTIRE POST BEFORE ATTEMPTING THIS PROCESS. IT’S NOT ROCKET SCIENCE, BUT IT IS FAIRLY INVOLVED AND ENTAILS SOME RISK. THERE ARE SOME WARNINGS AT THE END.*
||
REQUIREMENT
Move iTunes media (music, videos, podcasts) to another folder and update the iTunes library to reference all the media from that new folder.
||
Example cases: Move iTunes media from C:\ drive to D:\ drive; Change iTunes folder name from Music to Media.
||
Note:
Special action is only necessary if the +Keep iTunes Media folder organized+ option is not selected. If this option is selected, iTunes will move media to the new location when the +iTunes Media folder location+ is changed. More info can be found here: http://support.apple.com/kb/ht1449
||
||
PROBLEM
When the location of iTunes media files changes (files are moved, folder name/drive letter changes), iTunes cannot automatically locate these files. iTunes entries can be updated to point to the new location one at a time or by deleting all entries and re-adding all files. Updating one at a time is time consuming, and deleting and re-adding causes a large amount of metadata (play count, date added, rating, etc) to be lost.
||
||
SOLUTION
The iTunes library can be exported to an XML file, modified, and re-imported.
||
Process:
- *Backup the iTunes library data:* Make sure iTunes is closed, and then backup the folder containing all the iTunes library data. This can normally be found in +<user-folder>\My Music\iTunes+ for Windows, or in /Users/<username>/Music/iTunes for Mac. The +iTunes Media+ and +Mobile Applications+ folders can be excluded from the backup since they will not be affected by this process. If this process does not work for some reason and you need to restore the previous state of your iTunes library, you’ll need to use this backup as the source for restoring.
- *Move iTunes media files to new location:* This may be changing which drive is used to store iTunes media files, renaming a folder, or whatever. This can be done for the whole library or for only part of it.
- *Export the iTunes library:* In iTunes, select File -> Library -> Export Library... and save the file somewhere for editing (Desktop is a good location).
- *Open Library.xml in a decent text editor:* Notepad is not recommended, since Library.xml can be very large. Some free options include PSPad, Notepad++, Smultron, and Text Wrangler.
- *Update Library.xml:* Locate the files that have changed location and update their path accordingly. The XML file has the metadata for each file labeled with XML tags. The file location is denoted by <key>Location</key>. If the whole library is being moved, a find/replace on the whole file is recommended. Once a file is located in Library.xml that needs to be updated, copy the part of the string that has changed starting with <key>Location</key>. Use that as the find parameter, and enter the replace parameter in the same format. Include as much of the string as possible to prevent unintentional replaces. Save and close the file when done.
- - - Example: Find: <key>Location</key><string>file://localhost/C:/Data/iTunes/
Replace: <key>Location</key><string>file://localhost/D:/Data/iTunes/
- - - Note 1: This step may require adjustment to match your situation. You may want to count how many files need to be updated and make sure that the find/replace only changes that many or edit them by hand if the location of all files have not been changed. It shouldn’t be difficult, but it may require some thought.
- - - Note 2: Music, TV Shows, Movies, and Podcasts are stored in this file, so make sure to account for all media types. If the location of all types didn’t change, the find/replace strings will need to take that into account.
- *Remove all modified media entries from iTunes:* For any of the files that are being moved, the associated metadata must be removed from iTunes to avoid having duplicates in iTunes. This can be done by selecting all entries in iTunes that will be modified, right-clicking the entries, and choosing “Delete”. After confirming that you want to remove the selected item from your iTunes library, make sure to choose to keep the file in the iTunes Media folder if prompted.
- *Import Library.xml:* Import the modified Library.xml by selecting File -> Library -> Import Playlist... and selecting the modified Library.xml in the file open dialog that appears. Depending on the size of the iTunes Library, this could take a while (10 minutes or more).
- *Test results:* Locate a file in iTunes that has been moved, right-click on the file, and choose “Get Info”. The “Location:” field should indicate the new location of the file. Close the Info dialog and try to play the file. If the file plays, the process was successful.
||
||
_*DISCLAIMERS/ADDITIONAL NOTES*_
- I tried this out a couple of times, and it worked fine for me. I can’t guarantee it will work for everyone, but I thought I’d share since I couldn’t find instructions for this situation anywhere else.
- If the process fails, you SHOULD be able move the iTunes media files back to their old location and restore the backed up iTunes library data to the iTunes folder to restore your previous configuration.
- I wouldn’t recommend attempting this if you don’t feel comfortable with backing up your iTunes library data and editing the XML file.
- I don’t know if this process will preserve whether videos and podcasts have been played or if it will preserve the play position where items were last paused.
- If you are moving all of your iTunes media files, you’ll want to update the “iTunes Media folder location” under the “Advanced” tab in preferences. This appears to be the folder that iTunes will use for some of its basic operations, such as storing synced audio notes, Podcasts, and the “Automatically Add to iTunes” folder.
- This process duplicates playlists, probably because you are importing your entire library again. I just deleted the duplicates when I was done.

If all the media is on one drive and you're not letting iTunes manage it then you can achieve the "portable" status simply by moving the library files high enough up the tree, i.e. the root of the drive if necessary, letting iTunes know where the nominal iTunes media folder is and then moving the library to the new drive keeping the relative paths from the library files to each distinct set of media folders unchanged. Personally I don't like iTunes cutting my file & folder names short, but the advantages of a portable library mean that I'm quite happy to organise my media inside the iTunes Media folder, albeit largly on my own terms. Indeed all my non-iTunes multimedia is now also organised in the same folders. The only media files iTunes organises, temporarlily, are rips & downloads apart from active Podcasts whose folder names I leave unchanged. Everything else gets sorted just the way I want it - full length filenames, different character replacements, folder art etc. I used to do it by hand, deleting, tweaking & reimporting, but these days I use a custom script which does it all automatically - renaming files just as I want and reconnecting iTunes to the newly moved file so that no iTunes-only metadata is lost.
There are similar XML-editing how-tos elsewhere on the web, I just wanted to make the point that there may still sometimes be a way to achieve the desired result which isn't quite as complicated but nevertheless leaves the user fully in control of their file structure.
Anyway, at least you took the trouble to find a method that works for you first. There are sadly too many tales of woe on these boards from people who've moved all their files around first only to discover that they've broken their libraries and can't work out how to undo the damage.
tt2

Similar Messages

  • How to change iTunes Media Folder location after Hard Drive Died

    I have been trying to figure this out from other posts but can't seem to find what I am looking for. I store all my music files on an external hard drive. Recently, the external drive died on me. Fortunately, I had the external backed up on another drive using Time Machine. I bought a new drive for the music and transferred the files onto the new drive. My question is what do I do next? Currently iTunes still searches for the files on the dead drive and I get the exclamation marks next to each song which is obviously not a surprise. I want to change the Media Folder preferences to the new drive but will I then lose all my playlists? Basically what I want to do is direct iTunes to the new drive and keep everything else intact. Is that possible? Any help would be greatly appreciated!
    Thanks,
    j

    You might read what this has to say about consolidate and dupes.
    http://www.keyscorner.com/archives/2009/03/07/removing-duplicate-files-in-itunes /
    More info here on consolidation:
    http://www.ilounge.com/index.php/articles/comments/moving-your-itunes-library-to -a-new-hard-drive/
    Message was edited by: Diane Wordsmith

  • Lost iTunes Libraries After Changing iTunes Music Library Location

    I followed the iTunes topic: Moving Your iTunes Music Folder article. Now when I hook up my iPod, I get an error message saying that my iPod is synched to another library - my only choice is to "Erase and Synch" or "Transfer Purchase" copies to this library...meaning that I would lose dozens of personal CDs that I have copied into the library. HELP!!!

    I too have tried lots of things as my music collection outgrew my laptop, so stored all tunes on an exteranl hard drive and found that, when i wasnt looking, crafting old Itunes had changed my storage location to default. I posted on here, and like this thread got lots of people wanting to know the answer to the same thing. One outcome seemed to be that if you start itunes before your computer has recognised the external drive that itunes is looking for, it will regiaster the drive as not available and revert, without telling you, to default location.
    Extremely irritating...
    just a little add to the last comment about the software.. i agree, for a product that has sold millions and is downloaded millions of times i find it hard to believe they cannot get this right. Stupid things like this, not giving a notification that its changing to default location, abnd only realising when half my music and podcasts have gone missing, not rescanning the itunes folder for new tracks automatically on opening or by refresh to find new tracks added by, shock horror to apple, other download stores. Not allowing you to set several pre determined folder paths so most like most people you can have 3 maybe 4 completely different areas to save your music in and still ask itunes to not only find it every time, but update from it as and when you need to, not when it thinks you might want to, ie, never, and have the ability to recognise everything else added not via itunes.
    For a world wide product it is simply awful. It would seem to me that one person in their spare time is developing this.
    oh and last thing, maybe that one person should concentrate on doing proper updates and stop bugging me with a new 7.6.5.4.8.5.23 update over 7.6.5.4.8.5.22 i updated yesterday, and 7.6.5.4.8.5.21 the day before...
    rant over... apologies if i bored anyone...

  • I am trying to move my iphoto and itunes to an external hard drive to free up space on my macbook...i have followed the steps to the change itunes media folder location (chosen external hard drive) but my new folder is greyed out so cant continue ?help?

    I need to free up space on my macbook pro as hard drive is full!! So with 20 000 photos/video clips and itunes I would like to move this to a external hard drive!
    I have followed steps on apple support but when i get to the Change itunes media folder location and chosen external hard drive it will not let me access the new folder option ?? help?

    errrrrrrm!
    Yes external drive shows up in finder on desk top and can change to in the media folder location thing!
    My external hard drive is a WD Elements. I have no idea about permissions to the external? Do i Have to format external hard drive to a mac?
    I am trying to follow the steps on the apple support page to transfer files (consolidate library etc) just cant get further down steps as the new folder option is greyed out!
    Thanks for you help

  • How can I transfer my iTunes Media Library from one PC to another without losing files and making a mess of the file and album structure?

    I have imported a number of Café del Mar CD's to iTunes, and iTunes keeps scattering the tunes into several different folders in iTunes Media. It also has trouble finding album information, unless it has been downloaded from iTunes Store. Previous versions of iTunes I have tried didn't have this problem.
    I've tried to tidy the files manually in iTunes Media, but that usually results in duplicates, so I stopped messing with it. I actually wouldn't mind iTunes blowing up my albums into a nightmare file structure of hyper categorization in iTunes Media (Album, Album Artist, Artist, etc.) if only it recognised its own mess when I transfer the library from one iTunes library into another.
    An example: I downloaded Cafe del Mar - Essential Elements featuring 13 tunes, two of these can be found in the files Cafe del Mar/Cafe del Mar Essential Elements, iTunes also created the folder Cafe del Mar/Cafe del_Mar Essential Elements containing 0 tunes!?! and the rest of the tunes are found under Rue de Soleil in the root folder, indicating ONE of the artists as the criteria for creating a folder of tunes!?!
    I am trying with every fiber NOT to hate this program, and would appreciate it if someone could explain to me how I can move an iTunes Media library of aprox 54 gb from my desktop via an external harddisk onto my laptop. I have tried 4 times, and everytime the result varies. Sometime I transfer 3000 files, other times 4000. Which files follow and don't is random. I lose files tranferring to the external harddisk and lose even more files from the external disk to the new library on my Lap. Do I have to transfer song for song or can this genius program actually transfer a larger amount of files without losing half the files and duplicating the rest?
    Is there a limit of size or amount of files?

    Backup with this User Tip, restore the library to the new computer using the same tool, keep the backup up-to-date in future. Deauthorize the old computer if you no longer need to access protected content on it.
    As to your issues with compilations albums select all the tracks, set the Album Artist to Various Artists and on the options tab set Part of a compilation to Yes. See Grouping tracks into albums for details.
    tt2

  • How to automatically add new files to external iTunes Media Library

    I have an external hard drive that I store all of my music on and have set as my iTunes media file location. When I connect it, I open iTunes and can play all of my songs off of the hard drive with no problem. But many times I do not have my external hard drive plugged in when I purchase and add new files onto iTunes. Because of this, even though I have my preferences set to automatically add new iTunes files to the external media folder, when I connect my hard drive, the files will not be on the hard drive's media folder and they will not immediately transfer over to the hard drive, and I will then have to add them manually. Is there a setting that I can use that will set all new or recently added files on my iTunes to be transferred over to my external hard drive once it is connected? Or maybe a command that compares my iTunes with my external media file folder and transfers all new media over to my external folder? Any help would be appreciated.

    Well I actually found something that was fairly close to what I was looking for. If you right click a file or selection of files then click the option 'consolidate files' you can copy them to the media library. I guess I'll just have to filter my recently added playlist by the right amount of time then use the consolidate option. I still think that making a feature that automatically copys newly added files to the external media folder once it is connected would be a very worthwile investment in Apple's time

  • I moved my itunes media library to an external drive to free up 40gigs.  How do I recoup my 40gigs?

    I moved my iTunes media library to an external drive to free up 40gigs on my hard drive.  When I checked in about this Mac to see if the space was gained it now seems to be replaced by a category "backups".  How do I recoup my 40gigs?

    When you moved the iTunes data to the external HDD, I assume you deleted it from your MBP.  Backup are not to worry about.  Read this:
    http://support.apple.com/kb/PH14329
    They will be deleted when disk space is required.
    Ciao.
    In addition, read this Apple support article:
    http://support.apple.com/en-us/HT4878

  • Cleaning up hidden files after deleting iTunes media library

    Recently I have been struggling with an almost full hard drive. Daisy Disk Utility revealed that a major culprit was a bulging iTunes  - 90 GB!
    In order to free up space, I have just copied iTunes media library to an external hard drive, successfully changed my iTunes preferences to point to the hard drive...that all worked.
    I then moved my iTunes media library to Trash.
    Most of it has now been deleted (there are still a few recalcitrant items I am trying to work out how to get rid of).
    I now have about 20 GB more free space on my hard drive....much less than I had hoped to gain. 
    Daisy Disk Utility tells me that I now have around 68 GB in hidden files.
    What can I do to finish the process of creating more space on my hard disk?

    Yes.  The following files and folders are in the Mac iTunes folder: 
    Album Artwork
    iTunes Music
    Mobile Applications
    iTunes Previous Libraries
    iTunes 4 Music Library.itl,
    iTunes Library Extras.itdb,
    iTunes Library Genius.itdb,
    iTunes Library.itl,
    iTunes Music Library.xml
    iTunes Library.xml **this file not in PC iTunes folder**
    .DS_Store and sentinel (icon for both is a blank sheet) are in the PC iTunes folder, but did not copy to iTunes folder on hard drive.
    The day before you responded to my question, I read a support document (in Home Sharing section)  that had instructions to import the playlist by copying iTunes Library.xml to external drive and importing it to  iTunes. I imported it by going to iTunes, File, Library, import playlist.  It worked, but again, no playcounts ratings.
    I thought iTunes Library.xml file was simultaneously removed when I removed the iTunes Folder in the Mac music folder, but somehow, I did something to get it back in or didn't properly remove it.  The .xml that's on my PC and in the ITunes folder on my external hard drive is iTunes Music Library.xml.  iTunes Library.xml is also on the external drive as a separate file but not in the iTunes folder that's on hard drive.  I did nothing to alter file names.

  • Import iTunes Media Library, some files were not found problem

    Hi guys,
    I am trying to restore my music library info via importing from iTunes Media Library xml file I backed up. During import, iTunes gave me error message box saying that some files were not found and therefore won't get imported. After it's done, I checked the iTune and I noticed many of the music files did not get imported at all, even their locations are correct. Is it because iTunes stopped importing at the first entry that it found its location not existed and therefore skipped the rest all along? Even later ones might be valid. Is this the case?
    Is there an easy way to find out what those entries are? So perhaps I could go and edit them directly in the xml file. The message box did not give much information
    Any help would be really appreciated,
    Thanks alot
    Windows XP Pro
      Windows XP Pro  

    Hi Chris
    I have now experimented a little more and discovered that although Time Capsule (TC) is showing in Finder as a Shared Drive at laptop startup (and showing a status of a connected user, me) it is not actually 'mounted' in the true sense of the word i.e. the unmount/eject symbol is not showing next to it nor either of the drives connected to the TC. By clicking on either of the 2 drives (i.e. the TC 'Data' disk or the TC USB-connected drive) the status changes to show the dismount symbol on both the selected drive and the TC in the Finder side bar. Launching iTunes after this intervention works every time as per your advice. Not the Apple 'it just works' that I have come to expect and appreciate but at least I now understand how to make it work reliably..........many thanks and I hope Apple just makes it work sometine in the future

  • HT1364 My iTunes media library...

    My iTunes media library resides on a WD "My eBook", I connected it to a new PC running Windows 7 and iTunes 10 and I need to get my iTunes library here instead, how do I do this? Thanks!!!

    Do you also have the iTunes Library.itl file that normally resides at <User's Music>\iTunes\iTunes Library.itl?
    If you do then having installed iTunes on the new computer, close iTunes, then click the icon to lauch it and immediately press and hold down the shift key. Keep holding until asked to choose or create a library. Click choose and browse to the library file.
    Otherwise use the same shift-start iTunes process to create a new library at X:\iTunes where X: is the letter of your drive. Once the library has been created merge your current media folder with X:\iTunes\iTunes Media then use File > Add folder to Library to import the folder X:\iTunes\iTunes Media.
    If you have any Apple devices see also Recover your iTunes library from your iPod or iOS device.
    tt2

  • HT4946 how to change the back up location on windows 7,c drive is almost full

    how to change the back up location on windows 7,c drive is almost full

    This is not a feature of iTunes.
    See this thread for way to "trick" iTunes into backing up to a different location:
    https://discussions.apple.com/message/20590667#20590667

  • Bought an iPod Classic.  First iPod, had a Zen for years, I want to transfer my music library, approximately 15,000 songs without creating an iTunes Media library.

    Bought an iPod Classic.  First iPod, had a Zen for years, I want to transfer my music library, approximately 15,000 songs without creating an iTunes Media library.  All of the music is currently in WMA format.  As you can imagine, 15,000 songs takes up a lot of space and I do not wnat it duplicated on my harddrive in an iTunes Media Library.  What are my options?-Shawn

    Change your mind, or change your device.
    You can't put wma files on an iPod classic. You can't put files onto an iPod without adding them to a media library first.
    tt2

  • How to change app store country location in iphone 4s with ios 7.0.3

    how to change app store country location in iphone 4s with ios 7.0.3

    Settings > iTunes & App Stores > Apple ID: > View Apple ID > Country/Region...change here.

  • How to change default save as location

    hi,
    how to change default save as location in acrobat 7.0?

    Why is Acrobat involved in this process at all? Why don't you save directly the pdf from your email program directly where you want it to be? Acrobat is just adding another step to this process.

  • How to change the permission of a folder of a website hosted on Microsoft Azure. I would like to know how to enable read write permission for this folder

    How to change the permission of a folder of a website hosted on Microsoft Azure. I would like to know how to enable read write permission for this folder
    Regards,
    John

    Hi,
    Please try to setting Folder Permissions on Web Publish, and then deploy it with Web Deploy, as far as I know, if we do that, Web Deploy will use the SetAcl operation to change permissions. Please have a look at the article below.
    #http://sedodream.com/2011/11/08/settingfolderpermissionsonwebpublish.aspx
    Best Regards,
    Jambor
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

Maybe you are looking for