References:
Procedure:
For these examples, assume the kernel assigns /dev/sdb to the device.
To find out, do:
fdisk -l
If your distro automatically mounts temporary media, do:
cat /etc/mtab
to see what is mounted. Then unmount it with:
sudo umount /dev/sdb1
sudo umount /dev/sdb2
etc, for each partition that got mounted
sudo apt-get -y install dosfstools
mkdosfs -F 32 /dev/sde1
To remove a partition:
fdisk /dev/sdb
Command (m for help): d
Selected partition 1
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-1015, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-1015, default 1015):
Using default value 1015
Command (m for help): t
Selected partition 1
Hex code (type L to list codes): c
Changed system type of partition 1 to c (W95 FAT32 (LBA))
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
WARNING: If you have created or modified any DOS 6.x
partitions, please see the fdisk manual page for additional
information.
Syncing disks.
![]() |
This site best viewed with a browser |
| Warning: This is a Debian centric site | |
| Many thanks to Debra and Ian Murdock for making Debian possible | |
| First created Dec 14, 2008 ~ Last revised November 26, 2009 |