7 Replies Latest reply: Jul 4, 2008 8:16 AM by Chris CA
TeaMan Level 1 Level 1 (125 points)
I've searched the forums for an answer to this question and haven't found any so here goes my question. Sorry if I gave up too soon in my search.

On my MBP laptop I have a slimmed down iTunes library and on a beefier external drive I have my full iTunes library. When I look at my local MBP iTunes folder I find 3 files...

iTunes Library
iTunes Music Library.xml
iTunes Library.xml

The folder iTunes Music is also in there but my question is about the two .xml files. Do I need both? I suspect one is older since it's Modify date is Oct 20, 2007. Since I recently switched to use my local iTunes library the first two files of the 3 above are dated today.

What is "iTunes Library.xml" file for? Can I delete it?

BTW... on my external master iTunes I only have the first 2 files. This 3rd mystery file doesn't exist.

Any ideas? Apple articles don't mention it that I can find.

Thanks.

15" MacBook Pro 2.4Ghz 4GB RAM, Mac OS X (10.5.4)
  • John Guo Level 5 Level 5 (5,265 points)
    iTunes Library has all the data about your play counts, playlists, and all other stuff that iTunes reads to know about your music. Without there's nothing on your iTunes programme even when your files are in the iTunes Music folder. iTunes Music Library.xml is for other programmes like the iLife suite. For example, when you view your photos with songs in the background and you open iLife browser, that the iTunes Music Library.xml telling iPhoto what music you have. As for iTunes library.xml you don't need that. That appeared probably because you had another iTunes library used in your computer before. You can delete that. The most important file is the iTunes Library file.
  • Chris CA Level 9 Level 9 (77,410 points)
    The iTunes music library.xml is created when the iTunes library is in a different place than the default.
    The iTunes library.xml is the default.

    iTunes does not use the .xml files. They are simply created by iTunes for other applications to use to access iTUnes.
  • TeaMan Level 1 Level 1 (125 points)
    So... given that I may have other apps that want the .xml file, which one in my case should I keep? I get that the iTunes Library is all iTunes app needs but of these other two .xml files... It's not clear if I can delete one because it's redundant or do I need to hang on to both?
  • Chris CA Level 9 Level 9 (77,410 points)
    Actually, you can delete both. iTunes will recreate what it needs.
    To check it out, quit iTunes, drag the .xml files to the desktop then relaunch iTunes.
  • John Guo Level 5 Level 5 (5,265 points)
    I said that you don't need the "iTunes Library.xml" file. You can delete that but keep the other two.
  • TeaMan Level 1 Level 1 (125 points)
    I am reading two different responses here. If the .xml file is used by other apps, then how does iTunes know to create the .xml file for them? Sorry but this story isn't making sense. I removed the iTunes Library.xml file from the iTunes folder and it was not created after opening and closing iTunes app. Didn't try the other one.

    Still not sure I have an answer yet. But thanks all for your discussions.
  • Chris CA Level 9 Level 9 (77,410 points)
    If the .xml file is used by other apps, then how does iTunes know to create the .xml file for them?

    Because iTunes is designed to create this file for other applications to use to access iTunes.
    iTunes does not use the .xml file for itself.
    If it does not find one, it recreates it (only for other apps) but it will not open it or get any info from it to use.
    The only thing it does is see if it is there.

    http://support.apple.com/kb/HT1660
    *iTunes Music Library.xml*
    "This file contains some (but not all) of the same information stored in the iTunes Library file. The purpose of the iTunes Music Library.xml file is to make your music and playlists available to other applications on your computer. In Mac OS X other iLife applications (like iPhoto, iDVD, and iMovie) use this file to make it easier for you to add music from your iTunes library to your projects."