Disk Utility in Terminal
List available volumes:
1
2
3
4
5
6
$ diskutil list
[...]
/dev/disk2 (internal, physical):
#: TYPE NAME SIZE IDENTIFIER
0: FDisk_partition_scheme *31.3 GB disk2
1: Windows_FAT_32 NO NAME 31.3 GB disk2s1
Format to specific file system:
1
$ sudo diskutil eraseDisk FAT32 NO_NAME MBRFormat /dev/disk2
Format to EXT3:
1
2
3
4
5
6
# Install e2fsprogs
$ brew install e2fsprogs
# Unmount is important
$ diskutil unmountDisk /dev/disk2
# Format as EXT3
$ sudo $(brew --prefix e2fsprogs)/sbin/mkfs.ext3 /dev/disk2