Music album art cache taking up too much space - can I change location to external hard drive?

Hello


Sorry for yet another Music App Album Artwork cache folder question.


I appreciate that I use iTunes/Music in a very different way to most I imagine, so my problem may not be a very common one... sorry. I use iTunes/Music as an archive system for my electronically recorded vinyl collection, with each song having a jpeg picture embedded within it: a photo of the actual vinyl record label or cover, in the cases of LPs... to be perfectly honest... for LPs I have 3 JPEGs: label, front cover and back cover.... it may sound crazy, but there is a lot of beauty and incredibly interesting and helpful info in all of these pictures. Mostly Apple lossless files, some high quality MP3s… huge collection (70K + songs / roughly 1TB) literally years of 'work' -ask my wife ;). No downloads, purchases or other... just 'ripped' vinyl, so not a single file with a picture that isn't a picture of the record itself.


I had all the actual music files on an 5TB external hard rive, as well as the iTunes .itl file and (I assume) the iTunes artwork cache.


It all worked fine until a bit of a OS update jump: from Yosemite (or El Capitan?) to Monterey. iTunes disappeared, in came ‘Music’.


I really struggled with the search function - now called filter- which is failing: missing files in its search results which I can find using other search terms. Some of the ones initially missing from some searches are now appearing in the same search… so it may be something uploading in the background still? I use the search function all the time... the whole point for me is the archiving system: I need to be able to find the tune from the label, the producer, the rhythm track, the sub-genre, the era etc etc.... all this info is in the file ID tags which should all be searchable... sometimes I have to resort to flicking through artwork as all I can accurately remember of the tune is maybe the genre and colour/look of of the label :)....


So by far my biggest grief was with artwork. After a lot of forum browsing, I learnt where the artwork cache was (/Users/xxxx/Library/Containers/com.apple.AMPArtworkAgent/Data/Documents), found Doug’s useful scripts (https://dougscripts.com/itunes/index.php ) and managed to painstakingly fix the majority of the files’ artwork display. Roughly 10% still won’t load: artwork still clearly embedded in file as can be seen in the tiny display square adjacent to the ‘now playing’ song info display, as well as big and clear in the mini player window view).

This fix led to a new problem for me… of size… with the music artwork cache filling up with thousands of jpeg files… it soon takes on epic proportions, sometimes 90GB+ and makes everything slow / impossible to work the computer.


So my question is around a fix for this which does not involve any messing with the embedded artwork. Ideally I want both good artwork display (as comprehensive as possible) of embedded artwork on the Music software, but also minimal used space on the computer hard drive. If I had to chose, I would obviously go for less space on the hard drive so my computer remains useable… this is what I am currently doing: deleting all the accumulated JPEGs in the Music artwork cache on a daily basis…


QUESTIONs-

1/ Is it possible to get Music App to to store the album cache folder on an external hard drive?

2/ Better… I don’t remember ever finding a huge folder of JPEGs with iTunes folders… so I’m assuming iTune didn’t physically store all the JPEGs but pulled them out from the embedded file as and when needed? If this is correct… is there any way to make the Music App to this?


Thanks


Matt

MacBook Pro 13″, macOS 12.1

Posted on Feb 18, 2022 2:07 PM

Reply
Question marked as Top-ranking reply

Posted on Feb 19, 2022 3:38 AM

1/ You can try. For example you could move the Documents folder to say /Volumes/<New Volume>/ArtworkCache/ then open terminal, type ln -s, drag the Documents folder to terminal to add its path to the command, then drag in the Data folder from the original location and press enter to complete. The command in terminal will look a bit like this:


ln -s "/Volumes/<New Volume>/ArtworkCache/Documents" "/Users/<User>/Library/Containers/com.apple.AMPArtworkAgent/Data"


When complete any calls to files inside /Users/<User>/Library/Containers/com.apple.AMPArtworkAgent/Data/Documents actually go to /Volumes/<New Volume>/ArtworkCache/Documents. It should be transparent, unless Music uses some non-standard call that doesn't play nice with the symbolic link. iTunes used to break if you tried this with the media folder.


If it doesn't work you drag the link file /Users/<User>/Library/Containers/com.apple.AMPArtworkAgent/Data/Documents to the trash, and then move the Documents folder back from the external drive.



2/ iTunes uses an artwork cache stored in iTunes/Album Artwork. Images are stored in a container with a .itc2 file extension and there is a complicated arrangement of nested folders akin to a form of hash table. One would hope that the freshly designed Music app would be as efficient with its cache as iTunes, if not more so, but perhaps that is wishful thinking. 😕



tt2




Similar questions

3 replies
Question marked as Top-ranking reply

Feb 19, 2022 3:38 AM in response to M1998P

1/ You can try. For example you could move the Documents folder to say /Volumes/<New Volume>/ArtworkCache/ then open terminal, type ln -s, drag the Documents folder to terminal to add its path to the command, then drag in the Data folder from the original location and press enter to complete. The command in terminal will look a bit like this:


ln -s "/Volumes/<New Volume>/ArtworkCache/Documents" "/Users/<User>/Library/Containers/com.apple.AMPArtworkAgent/Data"


When complete any calls to files inside /Users/<User>/Library/Containers/com.apple.AMPArtworkAgent/Data/Documents actually go to /Volumes/<New Volume>/ArtworkCache/Documents. It should be transparent, unless Music uses some non-standard call that doesn't play nice with the symbolic link. iTunes used to break if you tried this with the media folder.


If it doesn't work you drag the link file /Users/<User>/Library/Containers/com.apple.AMPArtworkAgent/Data/Documents to the trash, and then move the Documents folder back from the external drive.



2/ iTunes uses an artwork cache stored in iTunes/Album Artwork. Images are stored in a container with a .itc2 file extension and there is a complicated arrangement of nested folders akin to a form of hash table. One would hope that the freshly designed Music app would be as efficient with its cache as iTunes, if not more so, but perhaps that is wishful thinking. 😕



tt2




Feb 19, 2022 3:54 PM in response to turingtest2

Thank you so much turingtest2, I have learnt a lot from your posts on this forum in the past so it’s a real pleasure to see your reply to my questions.


I have tried your suggestion but sadly failed -possibly due to being a novice with the Terminal App. I used the following command: 

ln -s /Volumes/Samsung_T5/Music/ArtworkCache/Documents /Users/<user>/Library/Containers/com.apple.AMPArtworkAgent/Data


This resulted in the following message:

ln: illegal option -- /  (or -- ?)

usage: ln [-Ffhinsv] source_file [link_name]

    ln [-Ffhinsv] source_file ... linkname_dir

    link source_file link_name


When tweaking the command in Terminal (adding spaces or “ symbols), on top of the message above, I got a variety of other messages such as: 


-bash: Users/<user>/Library/Containers/com.apple.AMPArtworkAgent/Data: No such file or directory

-bash: /Users/<user>/Library/Containers/com.apple.AMPArtworkAgent/Data: is a directory

-ln: /Users/<user>/Library/Containers/com.apple.AMPArtworkAgent/Data/Documents: File exists


But when opening Music after each command attempt load the artwork, the cache that starts accumulating the artwork JPEGs remains the original one (/Users/<user>/Library/Containers/com.apple.AMPArtworkAgent/Data/Documents) with no JPEGs being added to the ‘new’ one on the external hard drive.



Thanks also for the explanation re iTunes management of artwork. I want to share your optimism re Music App efficiency of managing artwork but remain doubtful as to the vale of storing all the individual JPEG artwork files (in no particular order as far as I can tell) on the internal hard drive… Intuitively, it feels like the Music App isn’t very good at managing artwork compared to iTunes.


Thanks again, I’m glad I tried. I think I might simply need to revert to iTunes, if that’s possible.


Best wishes

Matt

Feb 19, 2022 5:38 PM in response to M1998P

Hi,


I tried it here, My actual command was this:


ln -s /Volumes/Data\ Drive/ArtworkCache/Documents /Users/steve/Library/Containers/com.apple.AMPArtworkAgent/Data


where my external drive is called Data Drive and my user is steve. While apparently successful when I ran Music all the art was missing, so I deleted the symbolic link and moved the folder back. This restored artwork to Music when I ran it again which was a relief. I guess it might work if you delete the contents of the Documents folder which ought to force Music to rebuild it, but I don't have time and a suitable backup to want to test right now.




iTunes isn't supported by Apple on Catalina or later but if you're determined look up something called Retroactive. It could potentially break whenever macOS gets updated.



tt2

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 album art cache taking up too much space - can I change location to external hard drive?

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