Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

iTunes (10.4.0.80) on Windows 7 memory leak

I leave my computer on 24/7 and iTunes is usually running the entire time also. Every few days or once in a while I'll get messages such as 'iTunes cannot save Library/Not enough memory available'.



User uploaded file

User uploaded file


The only solution I have right now is restarting the program every few days. Any suggestions? My computer is always kept up-to-date with the latest Windows Updates. Microsoft Security Essentials detects no viruses or malicious files. As of the latest few updates I started getting these errors, sorry I don't know exactly when this started happening.

Windows 7

Posted on Aug 21, 2011 6:17 PM

Reply
32 replies

Oct 4, 2011 9:30 PM in response to gotchay

Experienceing the same problem only at a much more severe rate.


iTunes will run out of memory trying to sync hundreds of files through the file sharing interface finally throwing a "not enough memory" error. This memory is never released and iTunes needs to be restarted.


This particular bug makes one of our apps unusable.


Windows 7/ iTunes 10.4 and 10.5

Oct 27, 2011 4:54 AM in response to gotchay

I found this happeneing too since upgrading from 10.3.x to 10.4 and can't beleive its still there in 10.5.


Mine gets to between 1.2 and 1.6Gb before I get the 'Can't save library' error popup. If it happens late at night then the next day iTunes may be completely unresponsive - can't even bring it in to focus, so have to kill the process in Task Manager.


This iTunes instance has been running for 15min short of one day of continuous playback! and based on it's current memory leakage, it's about to fail.

User uploaded file

User uploaded file

User uploaded file



For what it's worth, you can downgrade to 10.3 (you should be able to find sites archiving previous versions - Apple used to provide a link on their iTunes page, but I can't find it now). I was running or over a week with no decernable memory leakage, but as I wanted to upgrade to iOS5 on my phone, I had to go to 10.5. I've got a MacBook Pro too, so may use that for iPhone updating and see if iOS5 will still sync music on 10.3 ...via direct USB connect of course!


But, you'll also have to find the various guides for downgrading.


Loosly put, you have to locate the backed up .itl files in your profile. It will have a date stamp in the filename to indicate when the upgrades took place.

i.e iTunes Library 2010-11-22.itl


It's a bit of trial and error unless you know how many upgrades you've done since 10.3!


On Vista/Server 2008, the path to the backups is

Users\<your user ID>\Music\iTunes\Previous iTunes Libraries


Make a copy of your current .itl (in the parent iTunes folder) and copy and rename one from the backups. You'll need to rename the file back to the same as the current one (iTunes Library.itl)



Hope this helps and hope that Apple pull the finger out of their cloud!

Oct 27, 2011 5:23 AM in response to Mr Anderson

Just in case anyone from Apple is following this, it seems that the leak is in the Theads being created. Not usre what actually triggers a new thread, it wasn't a track change, so something more subtle internally in iTunes.


Anyway, the image below shows new iTunes Entry thread being created and in doing so, the memory useage went up.


User uploaded file

The selected thread (Blue highlight) was first then within seconds while prepareing screen capture it, 2 more were added. Then there would be a pause (not sure how long exactly) and another thread or 2 added (Green highlights). This is by no means the absolute cause as the number of threads keeps going up and down. Some those thread types do expire and die away. I've been watching it for a bit and the Count: at teh top of the dialog hovers between 36 and 39 and the moment. Memory usage (the processes Private Bytes/Virtual Size etc.) has risen by 50+ MB since replying to this forum thread.


When iTunes became completely unresponsive the last time, the list of theses highligted thread was huge.

Oct 28, 2011 7:51 AM in response to arkayn

Thanks for the link, couldn't see their usualy link to previous versions at the bottom of their iTunes download page when I was look a week ago.


Anyway iTunes finally crashed. This is with 10.5 which failed differently to 10.4


User uploaded file


Nothing came up when clicking on Check for solutions.


Also, I noticed the the number of threads had reduced to 1, and it was consuming .40+ % of my CPU, hard drive is rattling away (probably swapping processes in and out) and my mouse is very stuttery

EDIT: Except the mouse stutter may have been due to running Process Explorer!!!


User uploaded file

User uploaded file


Interesting the crash dump shows JavaScriptCore.dll as being involved in the crash!

Oct 28, 2011 8:14 AM in response to Mr Anderson

Really Apple, you aught to be ashamed at yourselves. This is MS territory!!!


2 days and 2 hours of continous playback.


I'll try it all again from now as I may have contributed to it's failue by stopping Genius to see if it was eating all the memory. When it didn't give any back, I re-enabled it only to find that Step 2 (waiting for Apple to deliver results) failed with an iTunes store authentication timeout failure. It had already connected and passed auth. to send my library info. to them.


Again, that failure may be due to lack of memory as iTunes had eaten it all.


Anyway, Genius back on and got passed Step 3 within seconds.


Right, start the clock. 4:10pm UK time Friday 28th Oct. playback started.

Oct 31, 2011 4:00 AM in response to Mr Anderson

It crashed again, not sure how long this time as it was sometime over the weekend.


This time though, I got the Error poup indicating the iTunes library can't be saved. It was frozen by the time I got to see it - all I could do was right-click iTunes in the task bar and Close or kill the process in Task Manager.


If I use the task bar close method, it takes longer and then pops up the App Crash error posted above.


All in all, a pile of crap. Just hope the Mac version isn't as bad as I've just gone an got a Mac Mini to replace my ageing Windows PC.

Feb 28, 2012 10:59 AM in response to pirateofmayhem

Fortunately for me, I've moved on from my Windows Server PC to a Mac Mini. I've not had any problems with memory leaks with iTunes 10.5.x so far, yet I'm still plagued by a Microsoft product causing memory leaks in Mac OS X Lion - namely RDC.


I run 6 sessions to remote machines over SSH tunnels and then on to work via VPN, but when a connection to a machine drops momentarily or there's a network glitch, then one of the RDC sessions consumes between 1.6 and 2.5Gb memory. I can't quit the app gracefully as it will just hang and cause other desktop interaction issues like take focus anytime the mouse pointer moves!


Anyway, that's for another discussion!


Good luck with Windows and iTunes ... hope someone fixes the issue!!!

Apr 1, 2012 11:25 AM in response to gotchay

I too had the problem that iTunes reported it could not save the library file after it had been running for some time. I have Windows 7 64-bit with all current Microsoft patches running on an HP Compaq 8200 Elite CMT with 16 GB total memory. iTunes was clearly running up a against a per-process limit, since there was available memory. I had to kill it with the task manager, it would not response to pressing the "OK" button in the notification window and seemed to be looping.


As it happened, when I restarted iTunes it told me that an updated version was available, so I downloaded it and installed it. It claims to be 10.6.1.7 (the About screen doesn't give a build date, but Windows properties suggest 3/27/2012 as the build date).


It started with a reasonable memory footprint, but after running for about a day or so it's up to 725,324K (yes, that is over 725 MB of private memory) with 33 threads active. All it's doing is playing back randoms songs from my iTunes library. It has the largest memory footprint of any running application on my system, including Outlook (a notorious memory pig).


Threads seem to come and go, but the memory footprint just keeps growing and growing. Eventually I will have to restart it.


Regressing to an older version is only an option when you haven't added lots of content to your library. I did that a time or two when Apple recently broke the pause/resume interface on my Logitech keyboard, but once that started working again, I've been keeping up to date.


It certainly is irritating that Apple doesn't seem to be able to avoid a memory leak on Windows. Other than that, the software seems to be working correctly and reliably.

iTunes (10.4.0.80) on Windows 7 memory leak

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