Forum Thread: [NOOB]Question Regarding Fixing a Partition Table of a USB?

[NOOB]Question Regarding Fixing a Partition Table of a USB?

I have a 16gb usb stick which had a live version of kali 1.1. I wanted to install kali sana , so I formatted the drive using minitool and installed it using Universal USB installer. When I tested the usb it wasn't booting! Upon checking it I found that the partition table was corrupt!! Anybody here knows how can I deletethe existing partiton table and create a new one???

PS: I know how to do it on windows using diskpart , but I want to learn to do this on linux!!

1 Response

To list all of your partitions, type:
fdisk -l

At the bottom of your output there will be a little table. The space in between blocks of rows indicates it is different drives. Each row is a partition.

These are the names usually given to drives:
/dev/ed(a-d) = ESDI drive
/dev/hd(a-h) = IDE drive
/dev/sd(a-p) = SCSI drive
/dev/xd(a-b) = XT drive

Let's say your output had two drives and one of them was /dev/sda and you wanted to deal with that drive, type:
fdisk /dev/sda

Now you can obviously consult the help menu for commands, by typing m, but I'll just direct you to what you need for this question.

To list the current partitions on /dev/sda, type p.

You will see the partitions on that drive that will be identified as /dev/sda and a number at the end of each name. Each number is a different partition on that drive.

To remove a partition, type d and then you will be prompted to enter the number that identifies that partition. Check that it worked by typing p again. If you require anything else, consult the help menu (type m). To save and exit, type w (this writes the final changes to the partition table).

Feel free to ask any questions if something confuses you. Good luck.
TRT

Share Your Thoughts

  • Hot
  • Active