How do I delete Purgeable Space on a Mac?
How do I delete the Purgeable Space on Mac OS?
Mac Studio, macOS 14.1
How do I delete the Purgeable Space on Mac OS?
Mac Studio, macOS 14.1
If deleting Time Machine local snapshots didn't help you reclaim much free space, try the method below.
A more efficient way to delete purgeable space on Mac is by making a file that grows until the disk is full and then deleting the file. It's worth mentioning that previous attempts to create an empty file and then duplicate the file until it uses up your Mac's free space to force your operating system to clear purgeable space to store the file no longer works with APFS.
How to purge Mac hard drive with command lines:
If deleting Time Machine local snapshots didn't help you reclaim much free space, try the method below.
A more efficient way to delete purgeable space on Mac is by making a file that grows until the disk is full and then deleting the file. It's worth mentioning that previous attempts to create an empty file and then duplicate the file until it uses up your Mac's free space to force your operating system to clear purgeable space to store the file no longer works with APFS.
How to purge Mac hard drive with command lines:
Ran into the purgeable space issue while trying to update the SD nav card for my car. The Kia updater app does not recognize purgeable space as being available and would not download the update. I tried multiple times to delete files and manually purge with terminal, but could not gain any available space. I came across another posting that suggested turning off "optimize mac storage" under the iCloud settings. Did that, rebooted and watched the purgeable space number rapidly decrease. Downloaded the update and turned optimize mac storage space back on afterwards. Just need to remember to do this the next time around.
After trying all the suggestions I could find online (none of them worked for me). I sucessfully increased my 'free' space from 14gb to over 100gb by adding volumes on my Macintosh HD drive using disk utility. I would fill these volumes by copying large folders (roughly 80gb) from elsewhere on my mac and then delete remove/delete the volume. Every time I did this my free space increased.
As many others suggest your mac keeps files in this available space for other purposes (I think in my case it was for Google Drive but Im not sure). Then when it needs the space it wipes the secretly saved files. When you then delete the volume it leaves that space as 'free' for you.
I couldnt delete the snapshots as others have even though it did list one snapshot in disk utility.
My issue was linked to installing Native Instruments libraries which uses an installer called Native Access which assesses the available space on your mac from the 'free' space that you can see in disk utility.
Lost about 5 valuable hours on this issue. Im frustrated with Native Instruments not apple. I presume Apple is trying to speed up or make more efficient your future actions as opposed to increase profits (as others suggest on forums).
Anyway I really hope this posst can help others save many, many hours!
Thanks
hi just went thru this issue for a small MacBook needing >16gb to upgrade the OS, with 41gb available and 25gb purgeable, for whatever reason the OS upgrade doesn't trigger a purge. This solution in the Apple dev forum from 'dotster' provides steps to create very large file(s) of random stuff, this ran and sent the disk info bonkers and eventually this suddenly dumped the purgeable space from 25gb to 400mb; deleted the files to fully reclaim the available space and was able to comfortably proceed with the upgrade and the rest of my life with this mac.
Purgeable Space Problems | Apple Developer Forums
I had also done some other stuff before forcing the purge with not much impact - turned off cloud photo sync I didn't need and purged some other cache and cloud files I didn't need which should have freed up several gb but didn't do anything to the available space for some reason. Also turned off auto backup on TM advised somewhere. Following this whole process and OS upgrade, I am left with 48gb available and only 19mb purgeable.
I was able to clear my purgeable data successfully. I used Disk Utility>File> New Image and created images based on what size Disk Utility said I had useable on my HD. I had these created to my desktop for easy deletion later on. I ended up having to create 6 different images as after each creation the purgeable data would decrease and open up more space on the hard drive. I got the purgeable data down to 300 MB from 34 GB. I then deleted all the newly created images to trash and emptied the trash.
You (and the others concerned about the size of the purgeable space being report) should understand that manually purging does absolutely nothing except maybe give you a dopamine hit when you see the free space size bump up. Whether Finder or About this Mac is reporting 400 GB or 900 GB free made no difference to the OS and ow it works(how you feel about it might be different of course!).
APFS is a far more advanced file system than HFS+ was, and things like space recovery are so transparent to the user that there is almost no point in even looking at it. Or at least understand that you are looking at it for your own sake and not because it is necessary.
The purgeable space mostly consists of local snapshots of Time Machine, and also caches, sleep images, swap files and other temporary system files.
To DELETE:
yep! The above solution is actually one which works. "~/Test" did not work since dd is apparently not able to resolve "~".
There was an interesting behaviour too. "dd" stopped at a level of freespace before I ran TM and rebooted last time. Maybe, the first "Test" file was also too large, since it was around 150GB. "df -h ~" still reported space available and it was growing each time I ran it.
I started to start "dd" all over each time after "dd" said "No space left on device" with a bit different file names, like Test1, Test2, and watched what happens with "df -h ~". macOS started to purge disk space but this was slower than "dd" was taking it. So I needed to start "dd" over and over after each "No space left on device". I got to a level where "Get Info" for SSD reported only 370MB and 1GB was available.
After this, it took around 30s for "rm -rf Test*" ;-) to finish, but after this, I'm back to the "Avail" amount in the shell at the level which was actually reported in "Storage" in "Settings" which is what "df" tells you, plus "purgable" amount from "Get Info"! Thanks "soniksaint"!
I think Apple should provide some tools for this if they do not allow to upgrade SSD ;-)
I hope it helps others!
In the Terminal application, you can run the purge command which forces disk cache to be flushed and emptied. I would reserve this to a time when you have no open documents or running user applications:
sudo purge
Password:
Enter the administrator password. Nothing will echo to the screen. I do not run this very often as the operating system is quite capable of managing itself.
Although purgeable space is reported in various places, the system will quietly & automatically use purgeable space as it needs it. Also, a reboot usually frees up purgeable space, at least on your system drive.
ringspa wrote:
that doesn't magically happen either from what I and others here have experienced, the OS may never release the space until forced to do so and apparently the OS upgrade and other 3rd party application operations can't account for it and get blocked.
Everyone that I have ever encountered with this problem here on the forums has reported that deleted files do get purged within one or two days.
However, these kinds of storage problems are a major issue for many people. Free storage doesn't just magically go away. Something has to use it. If you don't identify and correct the problem that is causing all of your storage to be used, then you'll never, ever fix it.
If your storage problems are caused by simply having too many files, then deleting them, and waiting, is the definitive solution. But if you have some 3rd party app, or some out-of-control Apple task, that is using that storage, then you'll have to correct the underlying problem. There is no one-size-fits-all solution.
If you've been using Time Machine for some time you could have a buildup of local snapshots which are taking up space.
Launch Disk Utility and look to see how many local snapshots are on your boot drive. A while ago when I was running Ventura I was down to about 50 GB. I launched DU and saw that I had 50 snapshots. I deleted 49 of them of them and regained 360 GB of free space:
So give it a try and see if it helps. Always keep one snapshot for safety sake.
Purgeable space - Simple bin bash script to REMOVE purgeable safely.
I have found this script works perfectly to REMOVE PURGEABLE space:
#!/bin/bash
# Bin-bash script to remove purgeable file space
# Created on 20241205
# Change username in this script to Your user name by using FINDER - GO - HOME
# To Run script
# Open Terminal and type:
# bash /Users/username/Documents/generic.sh
# Create a text file with zero bytes then fill with lots and lots of zeros
set -x # Set Debugging Mode - Print each command as done
# set -e # Remove "#" sign for seeing Exit on Error for Debugging
cd /Users/username # Change to ~/HOME directory
touch text.txt # Create a zreo byte file called text.txt
# Fill text.txt with 100000 ZEROS at a time till no more space
dd if=/dev/zero bs=100m of=/Users/username/text.txt status=progress
# Delete LARGE ZERO file called text.txt
rm /Users/username/text.txt
echo "!!!! GoTo Macintosh Disk then select Get Info for Pureable Space !!!!"
echo " "
read -p "Do you want to loop again? (y/n): " answer
if [ "$answer" = "y" ] || ["$answer" = "Y" ]; then
bash /Users/username/Documents/generic.sh
fi
# END OF SCRIPT
exit
I hope you find it useful too.
Mac mini, macOS 15.1
Posted on Dec 5, 2024 4:16 PM
purge didn’t change anything
The purge Utility has absolutely nothing to do with purgeable space.
macOS should clear any purgeable space if needed. Some poorly written apps will check free space instead of asking for storage space and fail because of the way macOS manages it.
Another possible way to regain space on a boot drive is to remove all but the latest local snapshot with Disk Utility:
I don't know if the Terminal purge command removes them but you can try and check it out with Disk Utility. If not the use DU to remove all by the latest.
How do I delete Purgeable Space on a Mac?