Learning to Format a SD Card as FAT32 Using Mac Command Line

To format a SD card (or any other sort of disk you can connect to your Mac) using command line I do as follows:

Open terminal

Hit cmd + space to launch Spotlight, type terminal and hit enter.

Insert SD card

I use my Mac’s SD slot, but it could also be an external USB card reader, an external USB hard disk or whatever.

Identify SD card

In Terminal I type the command:

I might see something like:

In this case /dev/disk2 is my SD card.

Format SD card

I format the SD card as FAT32 giving it the name SDCARD using the following command:

sudo gives me super user rights.
diskutil calls the disk utility program.
eraseDisk is the command for formating.
FAT32 sets the file system.
SDCARD is the to be given name of my choice.
MBRFormat tells the disk utility program to format with a Master Boot Record.
/dev/disk2 is the location of my SD card.

I then am asked for my password. After confirming the formatting is runned.

Verify formatting

To check if the formatting had been successful I use above command again:

I can simply do this by typing the up arrow twice.

Ressources I’ve been using to learn this:



Leave a Reply

Your email address will not be published. Required fields are marked *

nineteen + 20 =