jrdave2304

Q: Changing Location of Media Files

I've done some searching but can't seem to find the exact answer I'm looking for, so apologies if this has been answered somewhere before....

 

I recently purchased a NAS and want to use that for my iTunes library. My iTunes media folder is currently users/NAME/Music and want to change it to Volumes/Music. I did a direct copy of my current media folder to the NAS. I opened the the iTunes Library XML file, did a find and replace of "users/NAME/Music" to "Volumes/music" fo all songs and changed the iTunes Media Folder location to Volumes/music. However, when I open the iTunes Library file from the NAS and look at the location of songs within iTunes it still shows it as the original location users/NAME/Music.

 

I must be missing a step (or going about the process completely wrong). Anyone have an idea of how I can get iTunes to look for my media files on the NAS instead of the old location?

Unibody MacBook 5.1, Mac OS X (10.5.6), Intel Core 2 Duo 2.4 GHz

Posted on Apr 26, 2014 2:51 PM

Close

Q: Changing Location of Media Files

  • All replies
  • Helpful answers

  • by Limnos,

    Limnos Limnos Apr 26, 2014 7:40 PM in response to jrdave2304
    Level 9 (54,353 points)
    Mac OS X
    Apr 26, 2014 7:40 PM in response to jrdave2304

    Several problems and confusions in your post.

     

    iTunes does not use the .xml version unless you import it.  Note that references in the .xml do not have date added, playcount, or ratings.  Typically you import the .xml to a blank library as part of rebuilding a broken library.  Importing essentially re-adds the links to the new library and the date added will be the current date, not the original one.

     

    Changing media location in preferences only has iTunes deposit new additions there in the future.  It does not get iTunes to read the location for things you may have moved yourself in Finder.

     

    A "library" is a complete set of library files plus media files.  You say you want to move your library but only mention media.  What do you want to do?  (I strongly recommend you move all the library intact to the NAS.  Just about every post I see with mention of NAS is some problem iTunes has in keeeping track of files which is made worse when people split their libraries.  I suspect getting iTunes to work properly with NAS is luck not design.)

     

    Quick answer on moving entire library if you use iTunes' default preferences settings:  Copy the entire iTunes folder (and in doing so all its subfolders and files) intact to the other drive.  Open iTunes and immediately hold down the option (alt) key (shift on Windows) so you get a prompt to select a library, then guide it to the 'iTunes Library.itl' file in the moved iTunes folder.

     

    If you put the copied iTunes folder in the default location of Macintosh HD > Users > *User Name* > Music  then you don't even need to start with the option key held down, iTunes will automatically look for it there.  (Make sure there isn't anything already in the iTunes folder there that you want to keep since you will be replacing it with the one you are moving.)

     

    Longer answers if for any reason you do not think all library files are inside your iTunes folder (changed preferences settings at some point):

     

    iTunes: How to move [or copy] your music [library] to a new computer [or another drive] - http://support.apple.com/kb/HT4527 - a somewhat bewildering and not always easily understandable set of options.

     

    For the record there's this reference for iTunes 11 but it really doesn't strike me as having the specifics you need. iTunes 11 for Mac: Move your library to another computer - http://support.apple.com/kb/PH12168

     

    2011 ilounge article: Transferring your iTunes library - http://www.ilounge.com/index.php/articles/comments/moving-your-itunes-library-to -a-new-hard-drive/  - An article with good background information (similar to the links above), particularly if you are not sure your media files are all grouped for quick answer above. Unfortunately under the single term "transferring library" it describes two very different moves; relocating just your media (not  really transferring your library and not recommended unless you really need this configuration), and relocating media+database (really your whole "library").  Make sure you understand the difference before electing to move only media.

    What are the iTunes library files? - http://support.apple.com/kb/HT1660

    More on iTunes library files and what they do - http://en.wikipedia.org/wiki/ITunes#Media_management

    What are all those iTunes files? - http://www.macworld.com/article/139974/2009/04/itunes_files.html

    Where are my iTunes files located? - http://support.apple.com/kb/ht1391

  • by jrdave2304,

    jrdave2304 jrdave2304 Apr 27, 2014 6:07 AM in response to Limnos
    Level 1 (0 points)
    Apr 27, 2014 6:07 AM in response to Limnos

    Apologies for not being 100% clear. I am moving all iTunes files, not just media. Right now the iTunes folder path is users/me/music/iTunes and media is users/me/music/<artist name>.  I copied everything in the music folder to the NAS, so that includes media as well as the iTunes folder and files.

     

    After doing so,  I did hit option and chose the iTunes library file located on the NAS and that's when I came here to describe the issue. I still have the original files in place locally. Should I delete/move them so that when I open up the new iTunes library file it can't read the files from that location any longer? Is there a simple way to have it relocate a mass number of songs?

     

    My basic goal is to have iTunes run off the NAS exactly as it did when it was stored locally (keeping playlists, play counts, add dates, etc.). The media folders and iTunes folder are in the same structure as before, just moved to a different location so I don't get why iTunes makes it so difficult to say here is my iTunes folder, here is my media folder... now read everything here instead of there.

  • by Limnos,

    Limnos Limnos Apr 27, 2014 10:54 AM in response to jrdave2304
    Level 9 (54,353 points)
    Mac OS X
    Apr 27, 2014 10:54 AM in response to jrdave2304

    Do you still have the "copy to" and "organize media" checked as per original default settings even though you changed the media location from default, or did you do all this structural organization originally yourself by hand in Finder?  If you did it the second way things will get tough.  If you let iTunes do it, you can try copying both folder to the NAS, start iTunes using the option key way, then see what set of files it tries to use or if it gives you a bunch of broken links.  If it shows broken links, try finding the file for one of the tracks using the copy on the NAS and see if iTunes can find the rest.  This will only work if you let iTunes organize your media all along.  If you did it yourself then iTunes will not even try to find the rest (or will fail).

     

    If you did it yourself you have two options.  One is to let iTunes do the organizing it wants to do and use the "organize" feature, designating the NAS as the place to keep media.  The other will to be as you did in editing the .xml version of the library file.  As I said before, iTunes normally never reads this file and you can do what you wish and it will in no way affect iTunes.  However, if you edit it and then (again as I said before) import it into a blank library it will use the data in the .xml as a basis for rebuilding the library (minus a few things mentioned before).

  • by jrdave2304,

    jrdave2304 jrdave2304 May 4, 2014 7:14 AM in response to Limnos
    Level 1 (0 points)
    May 4, 2014 7:14 AM in response to Limnos

    I did have iTunes organizing and copying my media in the original library FYI.

     

    I finally got it to work so figured I'd share the steps that worked for me. Keep in mind, I have a large amount of media which is why I didn't just skip to Step 3 and have iTunes copy it to the NAS location for me...

     

    1. Copied media folders and iTunes folder from old location (users/me/music) to new location (volumes/music).
    2. Also copied the media and iTunes folders to an external hard drive as backup because I then deleted the folders from the old location (users/me/music).
    3. Hold down "Option" while opening iTunes and click "Choose Library"
    4. Navigate to "iTunes Library.itl" in new location (volumes/music/iTunes)
    5. Go to "Advanced Preferences", change the iTunes Media folder location to the new location (volumes/music) leaving the "Keep iTunes Media folder organized" and "Copy files..." options both checked.
    6. iTunes will then "Organize" your media and then ask if you want your media copied to the new location (which you do, so click yes)
    7. Since my media was already organized and named properly in the new location there was no media actually copied during this process.
    8. Right click on any piece of media and "Get Info" to ensure the location is where it's supposed to be
    9. Done!

     

    The end of step 2 is what I missing before -- you must move/delete everything from the old location. If you don't do this, after completing steps 6 and 7 and clicking "Get Info" it will still show the media location as the old location. I was a little wary doing this as I had no idea if it would work... which is why I have to copies saved (one on the NAS, one on the external HDD).

     

    Thanks for your help Limnos!