4

I'm on mac OS 11.5. Last week I wanted to update my xcode command line tools and found this command on the internet

softwareupdate --all --install --force

Update to the xcode command line tools went fine, but this also tried to update my OS version to 11.6. I did not want that, so I did not enter my password and I am still on 11.5, so good so far.

However, it still downloaded the OS update which now blocks over 10 GB of my disk space. As I don't have any plans to do the update anytime soon, is there a way to free this space again? I already tried to reboot, but the space is still blocked.


I'm sure that the downloaded file is still there. If I run software update again I immediately get the output

Software Update Tool

Finding available software
Downloading macOS Big Sur 11.6.1
Password: 

Downloaded: macOS Big Sur 11.6.1

without the waiting time it would take to download a couple of GB on my internet connection, so it must access some cached file.

9
  • You can find this updates in /Library/Updates. In Finder focus you can do Cmd+Shift+G and paste /Library/Updates in open windows then validate an you can explore directories type XXX-YYYY
    – user415185
    Nov 21, 2021 at 12:37
  • @Jean_JD Thanks you for your comment, however this directory only contains two tiny .plist files
    – foo
    Nov 21, 2021 at 12:59
  • Have you verify the free space on your System Disk?
    – user415185
    Nov 21, 2021 at 14:32
  • @Jean_JD What do you mean with "verify the free space on your System Disk"?
    – foo
    Nov 22, 2021 at 11:21
  • You can use disk utility or terminal command : df -H to verify disk usage.
    – user415185
    Nov 22, 2021 at 11:34

1 Answer 1

2

On terminal run (type in your password and this account needs Admin rights on the mac):

sudo find /private/var/folders -type d -name "downloads"

On my Big Sur machine it returns a lot of 'Operation not permitted' but also two finds:

...
find: /private/var/folders/zz/zyxvpxvq6csfxvn_n00000z000007r/C/com.apple.quicklook.ThumbnailsAgent/com.apple.QuickLook.thumbnailcache: Operation not permitted
/private/var/folders/zz/zyxvpxvq6csfxvn_n00000s0000068/C/com.apple.SoftwareUpdate/swcdn.apple.com/content/downloads
/private/var/folders/zz/zyxvpxvq6csfxvn_n00000s0000068/C/softwareupdated/com.apple.SoftwareUpdate/swcdn.apple.com/content/downloads
find: /private/var/folders/zz/zyxvpxvq9csfxvn_n0000000000000/0/com.apple.LaunchServices.dv: Operation not permitted
...

Rather then on the former mentioned mount volume /System/Volumes/Update the /private/var/folders/ is part of mount volume /System/Volumes/Data .

The two interesting founds need a real root access. So from now on be really careful what you are doing on your system! On terminal run (type in your password and this account needs Admin rights on the mac):

sudo su

Now check your founded download folder on size used with du command. Here is the example I did on my machine:

%n@%m %1~ %# du -sh /private/var/folders/zz/zyxvpxvq6csfxvn_n00000s0000068/C/com.apple.SoftwareUpdate/swcdn.apple.com/content/downloads/*


0B  /private/var/folders/zz/zyxvpxvq6csfxvn_n00000s0000068/C/com.apple.SoftwareUpdate/swcdn.apple.com/content/downloads/00

...


29M /private/var/folders/zz/zyxvpxvq6csfxvn_n00000s0000068/C/com.apple.SoftwareUpdate/swcdn.apple.com/content/downloads/06

...


0B  /private/var/folders/zz/zyxvpxvq6csfxvn_n00000s0000068/C/com.apple.SoftwareUpdate/swcdn.apple.com/content/downloads/60

You see one folder on my machine is 29 MB large. So I followed this path to the end and list its content and found a partially downloaded Safari 15.0 there. This is interesting since I already have Safari 15.1 installed. Maybe a download of 15.0 was interrupted in the past and now still uses disk space here.

%n@%m %1~ %# du -sh /private/var/folders/zz/zyxvpxvq6csfxvn_n00000s0000068/C/com.apple.SoftwareUpdate/swcdn.apple.com/content/downloads/06/32/002-02865-A_VQHMW5SC23/x193wtjutj4ik3o83rn5fd5fh7xeb694yb/Safari15.0BigSurAuto.pkg.PKDownloader-Partial/CFNetworkDownload_7ILPuD.tmp 


29M /private/var/folders/zz/zyxvpxvq6csfxvn_n00000s0000068/C/com.apple.SoftwareUpdate/swcdn.apple.com/content/downloads/06/32/002-02865-A_VQHMW5SC23/x193wtjutj4ik3o83rn5fd5fh7xeb694yb/Safari15.0BigSurAuto.pkg.PKDownloader-Partial/CFNetworkDownload_7ILPuD.tmp

Now it is on to you how brave you are if you like to mess with the files here or not. Normally messing with files in /private/var/folders/ is a totally no go! I have not done this on my own and I don't know the side effects yet. I just show you how to find the download cache of softwareupdate. I hope you have backuped all your data just in case!

Added later:

I just found out a safe way to clear all the cache files of macOS is to boot your machine ones in safe mode. I tried this and now my partially loaded Safari 15.0 is gone. Then just boot again to be in normal mode again. See here at Apple how you do a safe mode boot: Start up your Mac in safe mode

4
  • Thank you for your answer! All the folders with update show with a size of 0B :(
    – foo
    Nov 23, 2021 at 12:44
  • Sorry to hear that. As you see in my case /private/var/folders/ really is the cache of unfinished downloads and a safe boot clears it. But maybe in your case the download was already finished and macOS has copied it from /private/var/folders/ to its target location where ever this might be?
    – Waitsnake
    Nov 23, 2021 at 12:52
  • Have you checked under /Applications folder if there is already an 'Install macOS Big Sur' App placed ? Other then that I can only advice you to use a third party tool like 'Disk Inventory X' to explore your disk for large files or folders. You need to give this tool temporary full disk access that it can do its job properly and can search all of your disk folders.
    – Waitsnake
    Nov 23, 2021 at 12:59
  • Yes, the download finished and softwareupdate gives as status "Downloaded: macOS Big Sur 11.6.1", so I assume it is really unpacked somewhere. I can't find any particular big file.
    – foo
    Nov 23, 2021 at 14:41

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .