private-schrijfsels-en-noti.../2025/Secure erase under macOS.md

2.2 KiB
Raw Blame History

Because you have a SSD installed in your MBP, you cannot use the 'secure erase', nor the 'erase free space' options in Disk Utility. It is better to boot your MBP into macOS Recovery while your SSD is protected with FileVault, then wipe the drive and reinstall macOS.

From this post at Backblaze are instructions on how you can also use Terminal commands whilst in macOS Recovery to do the secure erase you're looking for:

Securely Erasing Free Space on Your SSD

If you dont want to take Apples word for it, if youre not using FileVault, or if you just want to, there is a way to securely erase free space on your SSD. Its a little more involved but it works.

Before we get into the nitty-gritty, let me state for the record that this really isnt necessary to do, which is why Apples made it so hard to do. But if youre set on it, youll need to use Apples Terminal app. Terminal provides you with command line interface access to the OS X operating system. Terminal lives in the Utilities folder, but you can access Terminal from the Macs Recovery System, as well. Once your Mac has booted into the Recovery partition, click the Utilities menu and select Terminal to launch it.

From a Terminal command line, type:

diskutil secureErase freespace VALUE /Volumes/DRIVE

That tells your Mac to securely erase the free space on your SSD. Youll need to change VALUE to a number between 0 and 4. 0 is a single-pass run of zeroes; 1 is a single-pass run of random numbers; 2 is a 7-pass erase; 3 is a 35-pass erase; and 4 is a 3-pass erase. DRIVE should be changed to the name of your hard drive. To run a 7-pass erase of your SSD drive in “JohnB-Macbook”, you would enter the following:

diskutil secureErase freespace 2 /Volumes/JohnB-Macbook

And remember, if you used a space in the name of your Macs hard drive, you need to insert a leading backslash before the space. For example, to run a 35-pass erase on a hard drive called “Macintosh HD” you enter the following:

diskutil secureErase freespace 3 /Volumes/Macintosh\ HD

Something to remember is that the more extensive the erase procedure, the longer it will take.

Sourcehttps://apple.stackexchange.com/a/405605