Linux Mastering Development Ubuntu

USB thumbdrive is so messed up I can’t even delete the problem partition in gparted

I was testing out various operating systems on a spare laptop, flashing a USB thumb drive with various bootable images in order to do so. At some point something got messed up, and the drive is now so screwed up I can’t even delete the bad partition. The drive mounts correctly (it appears in my file manager and I can look through the files) but I can’t reformat it or delete the existing partition to use it as a normal thumbdrive again.

When I open gparted, I immediately get the message:

The backup GPT table is corrupt, but the primary appears OK, so that will be used.

The drive has one partition /dev/sda1, and a bunch of unallocated space. I unmount the partition in gparted and try to delete the partition. While deleting the partition, the same error appears again, along with:

Input/output error during write on /dev/sda

gparted then claims the partition was deleted successfully, but it still appears in the partition list afterwards, with various errors in the “Information” dialog:

Can’t open /dev/sda1: No such file or directory

Cannot initialize ‘::’

mlabel: Cannot initialize drive

fsck.fat 4.1 (2017-01-24)

open: No such file or directory

I don’t care about any of the data on the drive. Is there a way I can nuke it back into a usable state?

Leave a Reply

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