Music App freezes/hangs every time I quit it

Either when I command "q" or click "Music" in the top left and "Quit Music", it gives me the spinny rainbow and takes forever to quit. In the Activity Monitor, it says "Not Responding" and maxes out my CPU. I have 13,000 songs and about 150 playlists. I'm on the latest MacOS and have Monterey. I have talked to Apple Support for weeks with no solutions... eventually I gave up and decided to deal with it. However, I'm a DJ, so reliable apps shouldn't be a big demand.


It's an interesting bug, because if I simply open the app and close it, it will close instantly... but if I add songs to playlists, change metadata, delete songs, etc... it takes longer to close. It may not even be that though... for instance, the longer I have the app open, the longer it takes to close. If it's open for an hour, it'll take about 6 minutes to close. But that may not be the cause either, and obviously that shouldn't be happening.


I don't subscribe to Apple Music and recently unsubscribed from iTunes Match. If I force quit the app, it won't remember simple things like volume adjustments and start/stop times. they had me do everything to try to isolate the problem: reset the ram, build my music library from scratch and import every playlist individually (which took forever since I have 150 playlists), create a test account and see if the problem still persists there (which it did), send a log to the engineers (did this twice and never heard back from the engineers neither time... my senior support agent gave me the run-around and said they would patch it in a future iOS update... they didn't), convert all purchased music to mp3, log out/deathorize and log back in, deleting the preference files and reverting my settings, and consolidating my music library. My MacBook Pro is from 2019. I bought it brand new directly from Apple, which goes to show it's a software issue. It's sad how they've shifted their focus to Apple Music because they know they can squeeze more cash out of their customers from a subscription rather than buying songs from the iTunes Store.


If anyone else has anything that could help me with this, any input would be greatly appreciated. I have not been able to find anyone with the same issue online. I plan to start a new support case ticket when I get the time, but this isn't the only issue I've had with the Music app in the last year... I was getting suplicate playlists when syncing my phone so I turned off wifi sync. Then, I was getting the 13010 error for the longest time and it mysteriously went away... it could have been after I disabled my firewall from scanning the Music folder, but I highly doubt the fix was that simple... I'm betting it's their corrupt Music app. Sad how Apple charges so much for hardware when it's their software that makes any Apple owner too scared to update their iOS until they have to.

MacBook Pro with Touch Bar

Posted on Apr 8, 2022 2:49 PM

Reply
Question marked as Top-ranking reply

Posted on Apr 9, 2022 10:49 AM

One other thing that might help when Music has done something odd is to option-start-Music and explicitly select your active Music Library.musiclibrary file. It seems that Music uses a hidden cached copy of the database to support home sharing and syncing with Finder when Music isn't running. It is perhaps possible that a damaged cached version may remain in use after a crash, or after restoring what should have been a known good copy of the database from backup.


tt2

Similar questions

16 replies
Question marked as Top-ranking reply

Apr 9, 2022 10:49 AM in response to MadAtApple69

One other thing that might help when Music has done something odd is to option-start-Music and explicitly select your active Music Library.musiclibrary file. It seems that Music uses a hidden cached copy of the database to support home sharing and syncing with Finder when Music isn't running. It is perhaps possible that a damaged cached version may remain in use after a crash, or after restoring what should have been a known good copy of the database from backup.


tt2

Jun 2, 2022 11:08 AM in response to uberTof

Just giving you an update that I'm still having this issue a couple months later. The only way to prevent it is by holding option and command when opening the Music app, as it does not hang when closing when I do that. I still have a feeling that it's something super specific that our files/Macs have in common... why would it work fine in safe mode but not normally? Until we can answer that question, we'll have to deal with it this way.

Apr 9, 2022 10:21 AM in response to uberTof

Sorry, this is a long read, I have a lot to say in response...


It's comforting to hear I'm not the only one this is happening to. I've searched Google so many times for threads about this, and even tried searching in certain date ranges, and no one is having this specific issue. And thank you for your reply. I would not delete a bunch of songs to try to fix it... the last time I got off the phone with Apple support, they said to create another account on the Mac and put the library on that account and see if the problem persists there. The problem is, I already tried that with another support person with no luck.


& I totally understand where you're coming from with not wanting to mess up your vast library. When one of the support people had me create a new library and import my playlists back one at a time, I lost all my volume adjustments, start and stop times, as well as all the date added timestamps on all my songs... It's one of the most frustrating feelings... it's like a piece of you and all the hard work you put in is now missing.


Fortunately, since then, I made a backup to an external SSD with a somewhat stable copy of my library. I also figured out a way to backup my MacBook wirelessly to a network drive, which I can share the link with you if you are interested. It's automatically backing up my computer as I type this before I try troubleshooting with the other comment on this thread.


Before I complain about them in the next paragraph, I must mention that it's not that the support people don't care about the work we've put into our libraries... they want to solve our problem so we can move on with our days... but some of their troubleshooting methods don't take into account what we'd lose if it's not the solution. It got to the point where I'd get on the line with a new support person and I'd instantly demand to talk to a Senior Advisor, or someone who's focus is on media or the music app... they tend to be more polite and knowledgable, but on the other hand tend to not want to stay on the phone as long and will awkwardly ask to set up another call a week out, in their schedule/time zone... usually at a time when you're busy or don't feel like dealing with something that shouldn't be happening on a new computer in the first place. Like dude, it's your job to solve this for me right now. And since this problem only happens when you've been making edits to your computer library for a while, it's extremely difficult to reproduce the problem and isolate the cause to prove or show it to them, especially without messing up your library, which they've sadly already caused me to do a plethora of times and it takes forever to revert how they caused me to mess up my own library.


Anyways, the support people via phone call had the nerve to get on my case about where I got my songs from... I have spent a lot of money in the iTunes store and bought a lot of CD's in my day, so the last thing I need is someone nagging me about something unrelated to my actual problem.


They couldn't even isolate whether it was a software or hardware problem. Two of the times, they made me record logs to send to their engineers, but never did I hear back about what was causing it. One time the dude was like "yeah we patched that problem so just update to the latest MacOS"... didn't work. I've been having this problem (among others) since Catalina. & I try not to force quit as well because if you do it right after trying to quit, it won't remember simple things like which playlist you put a song in or changing a song name... so it then becomes a waiting game where you have to sit there and not get anything done until it finally quits.


One support person had me check the box in Settings > General that says "close windows when closing an app"... that may have helped for another issue I was having but not for this so I unchecked it again. Sometimes going to File > organize library and consolidating will make it not hang, but then it'll do it again the next session. A big part of me thinks maybe it has to do with when I was trying to isolate other problems for other errors and maybe I messed up a preference file or the files when you click show package contents on the music library file, or the transfer of songs from an old MacBook's iTunes version to the new Apple Music focused version... or having Itunes Match then unsubscribing... did you have iTunes Match at any point? It's different from Apple Music.


Also, please let me know if you experience the issue when you migrate music from your computer now to your new one.


Lastly, and obviously, if you find a solution, please let me know here. I plan to try the other comment's suggestion on this thread here in a minute and will keep this thread updated with my progress.


Thank you in advance and I wish us both the best of luck.

Apr 9, 2022 10:42 AM in response to MadAtApple69

All that time with customer support must have been the worst... I've avoided that so far.

Also, I'm lucky that I don't rely on using Apple Music for my livelihood as you do. That alone must be infinitely times worse.


To answer your questions:

  • No, I've never used iTunes Match. I never trusted their "music laundering" :) Also didn't want to pay any indefinite long-term recurring fees. Hence, my additional avoidance of paying for an Apple Music subscription.
  • Yes, I experience the same hanging after the transfer to my new 2021 MacBook Pro M1 Max.
  • Yes, I will absolutely respond here if I ever find a fix, as I know you will too for me.
  • Yes, while in Safe Mode I made playlist changes and it closes instantly and upon re-opening, the changes persisted. It wasn't open very long though.


I will say, the good news is that even though I had to force-quit a few times today while testing out the potential fixes from @tt2, every playlist change and play count update I made, and every song I re-downloaded still persisted upon re-opening the app. This basically means, for me at least, that Apple Music is functional as normal. I just have to wait forever or force-quit when done using it.


I'm still leaning toward the issue being with it's poor handling of large libraries.

Jun 3, 2022 6:55 AM in response to MadAtApple69

MadAtApple69, I just read a promising article about an Apple Music alternative called Next that works with either an Apple Music subscription or a local library and syncs your playlists and preferences across devices to iCloud!


I haven't used it yet and I don't know if it solves your DJ needs, but it sounds like it might be a work-around for the time being.

Apr 8, 2022 8:18 PM in response to MadAtApple69

I've had this exact same issue for perhaps 9 months now. I suspect you're right that it could be happening for larger libraries such as ours, because mine is close to 11,000 songs, coming in at 54GB, with 350+ playlists. I've spent hours and hours over the last 16 years crafting these playlists. Many of them are smart playlists based on factors such as star ratings and play counts, so rebuilding the library data from scratch is NOT an option for me, and it's a relief to hear that rebuilding isn't the solution.


Pretty much every factor you mentioned happens to me as well. If I open Apple Music I can close it immediately with no issue, but if I edit something, it hangs when I try to close, and after it's been open a long time it takes longer to close, sometimes overnight or not at all. I really hate force-quitting, but I have to sometimes.


I'm tempted to remove a big chunk of songs I don't care as much about in order to see if there is a certain library size that it can handle. But that would be rough because each song is like letting go of a child almost, hah.


FYI - I first experienced the issue on my 2014 27" 5K iMac probably about 9 months ago. It was probably running Big Sur or Catalina at the time, but I'm not sure. This week I transferred everything over to a 2021 16" MacBook Pro M1 Max, and as I write this post, I'm still waiting for Apple Music to close. It's been hanging for over 25 minutes...


This issue is frustrating because it feels like Apple doesn't care about people who still buy songs and manage large libraries. Hopefully they can fix it soon.

Apr 9, 2022 10:01 AM in response to turingtest2

I tried everything you suggested, but unfortunately, it still hangs when closing.


After launching Apple Music in Safe Mode I can close it instantly which is nice. However, after opening the app the normal way, and doing things like adding songs or tweaking a playlist, Apple Music is back to its old stubborn ways when I try to close it. After the main UI window finally closes, another small one opens with "Saving Music Library" which hangs a variable amount of time before either closing or just hanging around seemingly indefinitely.


I did have one .tmp file that was from 5 months ago. I tried renaming that and using it as my library db file, but it had the same hanging issue. I don't currently have any 3rd-party software that might have interfered. I also tried deleting cache files with no luck.

Apr 9, 2022 10:28 AM in response to uberTof

Thank you for trying those troubleshoots. It's saying something that it doesn't happen in safe mode... we need to figure out why that's the case. A part of me is not too optimistic though... are you sure you had it open long enough or did enough edits to your music library in safe mode before trying to quit it? If not, maybe it does have something to do with how big our music libraries are or where we get our music from.


I have also tried clearing the cache and deleting the Apple Music preference files in the past with no luck. I still have copies of my old preference files backed up to my desktop just in case lol. Thanks again.

Apr 9, 2022 10:37 AM in response to turingtest2

It seems the safe mode method temporarily fixed the problem for the other person on this thread with the same issue... why do you think that is? I want to remind you that my CPU gets maxed out when the Music app hangs while trying to quit it.


^ these are the contents of my Music library file when I click "Show Package Contents"... no temp files. Please let me know if this is what files should be in there and if that's what they're supposed to look like, as there's not much information online about it and it's constantly evolving with every MacOS/Music app update.


The only third party software I have is a virus scanner called BitDefender... I checked it yesterday and it doesn't do passive scans, only when you manually do them. I excluded the music folder from what it scans a while back and then I no longer got the "Error 13010 Cannot save music library file" issue that used to be a big problem for me... but I'm not confident that that's what actually fixed that problem.


Thank you so much for your help... Apple phone support would have me rebuild my whole library before having me try the simple isolation methods you've already mentioned.

Apr 9, 2022 10:57 AM in response to uberTof

Thank you for your prompt reply and for answering my questions. You're my hero. You're steering me in the right direction as well. It's good to hear that it remembers your changes when force quitting... as a DJ, I have been super careful with that and will even shut my computer when it's still in the process of quitting, only to have to wait again when I reopen my computer because it's still in the process of quitting. I've gone as far as turning off the cloud sync on my iPhone and syncing manually with a wire again... I ran into other issues, especially during my iTunes Match era (since it syncs to iCloud), where I would get duplicate playlists every time I synced my iPhone and it was very annoying reverting them without losing my playlists. I also turned off home sharing and logged out of my brother's computer and my work computer for other issues I was having, but this issue seems to be something else.


However, I want to make it clear that I'm not subscribed to Apple Music. As a DJ, I need to have physical, downloaded copies of songs. Even though I pay for a mobile internet hotspot (for downloading songs at gigs without wifi), I just can't rely on streaming songs at a gig like a wedding where it's the biggest day of their lives... can't afford any hiccups. The Verizon representative upgraded my plan to include Apple Music for free, but I'm too afraid to try it out... If I can solve this problem of the Music app hanging, I will not upgrade to the new MacOS versions any more lol... therefore, I will finally have a good working, stable Music app and will have it backed up in multiple ways on a frequent basis... so hopefully no more frustration and headaches due to Apple workers releasing unstable, not thouroughly tested MacOS versions.


Sorry again if all this is TMI. But anyways, you may be onto something when you say it's because of large libraries, but I feel like there'd be a lot more people with the same problem if that was the case... and they would have had to have patched it by now. So I have hope that it's still something simple and precise... like a corrupt song file type or something.

Jun 2, 2022 11:26 AM in response to uberTof

Right. Sadly, only the Music app has all my song information and can do playlist folders. I have Apple music included with Verizon, but cannot use it because it does not work with Serato (what I use to DJ). The only way it'd work is using a third party converter every time I want to play a song or use a playlist, which is simply not an option for me. Thanks for the update.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Music App freezes/hangs every time I quit it

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.