Wipe Flash Drive on MacOS

December 11, 2019

Something happened when MacOS went from OS X to MacOS: Disk Utility started sucking. For some reason, if a flash drive is bootable, I never have the ability to erase it using the GUI Utility. So, I always search for the proper syntax on how to do it.

Instead of continuously searching, this is a quick tip for myself:

sudo diskutil list
sudo diskutil eraseDisk FAT32 STORAGE /dev/DiskNodeID

9 times out of 10, on my MacBook, my flash drive is /dev/disk2. So the command becomes:

sudo diskutil eraseDisk FAT32 STORAGE /dev/disk2