7 Exercise Tips How to Stream 'Rabbit Hole' Roblox's AI Efforts 9 Household Items You're Not Cleaning Enough Better Sound on FaceTime Calls 'X-Ray Vision' for AR 9 Signs You Need Glasses When Your Tax Refund Will Arrive
Want CNET to notify you of price drops and the latest stories?
No, thank you
Accept

New Audio CDs unmounting after track name lookup

Some people have noticed an issue in Snow Leopard where iTunes will query for Audio CD track information and then promptly unmount the CD from the system.

When you insert an audio CD into your computer, by default iTunes will launch and query the Gracenote online database (formerly "CDDB") for information such as the album and track names. This information is then applied to the tracks when they are imported; however, some people are having an issue in Snow Leopard where iTunes will query for the information and then promptly unmount the CD from the system.

MacFixIt reader "Joseph Samocha" wrote us an email outlining the problem (also noted on this Apple discussion thread):

"After upgrading my Mac Mini Solo to Snow Leopard...[and inserting an audio CD] once the information comes up, it immediately disappears: Pretty much just a "flash." In conjunction, the CD is dismounted (no longer shown in iTunes nor Desktop) but not ejected.

Switching to Disk Utility shows that the CD is there but dismounted (grayed out Audio CD) and selecting it and using either Mount or Eject behaves as expected. If re-mounting, the CD, with CDDB information, appears on the Desktop and in iTunes. While this is a usable work-around, it is rather frustrating and it gets feels tedious (this is subjective after all it is just two more steps). This dismount happens for every new (to iTunes, this Mac) audio CD but not for any that have been seen before."

This issue happens only with new CDs that the system has not seen before, since after the CD has been read and unmounted, it will then mount properly every time. This problem only happens when iTunes is open, indicating the issue is with how the program handles the mounting and unmounting of audio CDs, and not with another aspect of the system.

When the track information is loaded for a CD, it is stored in a "CD Info.cidb" file that's located in the /username/Library/Preferences/ folder. With the information loaded, iTunes will unmount and remount the audio CD to mask the default names ("Track 1", "Track 2", etc.) with the new ones. It seems there is a bug when iTunes performs this process, where upon unmounting the program will sometimes not instruct the system to remount the CD.

To combat this problem, people have tried removing a number of obvious preference files, and reinstalling iTunes, repairing permissions, and even reinstalling Snow Leopard, but with no luck. I've found that regardless of the system or account settings or preference files deleted, the problem still happens, indicating it's an issue in iTunes that needs to be addressed by Apple.

In my testing, this problem definitely happens on all of my Snow Leopard machines when a number of new audio CDs are inserted, but as with others' experiences this does not happen for all CDs. It also seems to be specific for Snow Leopard, and does not occur on my PowerMac G5 running 10.5.8. With this bug, once the CD information is loaded in the "CD Info.cidb" file the CD will load properly every time which prevents further troubleshooting of the issue with that CD; however, luckily in many cases you can force the computer to replicate the problem by going to the /username/Library/Preferences/ folder and removing the "CD Info.cidb" and "CDDB Preferences" files and then inserting the CD again (keep in mind that deleting this file will remove all previously queried track information for your audio CDs, so back it up first).

I've narrowed the issue down a little by setting iTunes to automatically "Show CD" or "Begin Playing" when an audio CD is inserted, and also unchecking the "Automatically retrieve CD track names from Internet" option in the iTunes preferences. Upon doing this and then deleting the "CD Info.cidb" file, every time a problematic audio CD is inserted it will display on the desktop, load in iTunes, and then promptly unmount. Checking the system log in the console shows this message being repeated each time the CD is unmounted:

Nov 12 13:18:23 Tophers-Laptop UnmountAssistant[5586]: Volume unmounted successfully

This problem only happens when a CD is first inserted, and does not happen upon remounting the CD manually using various means. As such, the only current workaround is to set up an easy way to remount a CD when it has been unmounted. This can be done by ejecting and re-inserting the CD, using Disk Utility to select the CD and click the "Mount" button, or by running the following command in the Terminal:

diskutil mount DEVICE

In this command, "DEVICE" will be a label like "disk1" or "disk2" (disk0 is the default for the built-in hard drive, but these labels may change depending on your drive configuration). To check which label to use, close iTunes and insert a CD or DVD in the drive so it mounts on the Desktop, and go to Disk Utility and get information on the CD (right-click --> Information). The disk identifier label in the information list should be used in the command.

Once you've identified what device name is used for your CD drive, you can use this terminal command in an applescript, shell script, or automator workflow (via the "run shell script" action) to quickly remount an audio CD that has been unmounted, and if saved as an application you can place it in the Dock for easy access. Since it is the fastest way to remount the CD, this is my recommendation for people who are affected by this problem.

Entering this command in AppleScript Editor will run the command when this script is run
Save the applescript as an application so it can be run from the Dock
The same command in an Automator workflow
Be sure to save the Automator workflow as an application
The mounting program can be put in the Dock for easy access

While you may consider turning off the automatic handling of CDs either in the Finder or in iTunes, this may only make things more cumbersome, especially for those who manage a lot of audio CDs. Additionally, it will not provide a workaround for the problem since when iTunes is launched the CDs will just be unmounted anyway. Lastly, for any workaround to work, you will need to enable automatic lookup of track information on the internet. Without this, iTunes will unmount the problematic CDs every time, but with it enabled, while iTunes may unmount the CDs once, subsequent mounting of the CD will have it display and run properly.

I will continue to troubleshoot this issue and keep an eye out for solutions that crop up, but in the mean time lets hope Apple updates iTunes soon to better handle CD track names. You can let them know of this issue by sending them feedback or by filing a bug report (requires a free Apple Developer Connection membership).



Questions? Comments? Post them below or email us!
Be sure to check us out on Twitter and the CNET Mac forums.