Fixing a USB Flash drive that has been “corrupted” by balenaEtcher.

Recently I used balenaEtcher to create a bootable Linux drive. It is a nice Windows program that simplifies the process of creating Linux disks and is recommended by some Linux distro vendors.

After the program successfully writes a bootable Linux USB drive, the drive no longer appears correctly in Windows. That’s because a bootable USB contains certain drive partitions with filesystem types that are not visible to the Windows operating system.

This is not really a problem until you want to remove Linux from the USB drive and start using it, once again, as a normal drive for transferring files etc. Windows is unable to see the partitions correctly and is therefore unable to remove them, or format the drive correctly.

The only way I found to “repair” my pen drive was by using a computer that was already running Linux, in my case Ubuntu.

I used gparted, which comes already installed in Ubuntu, to remove all partitions on the USB drive, which for me was mounted at /sdb1/

You should take care that you are modifying the correct drive location!

Once I deleted any existing partitions I created a new partition from the unallocated space, with an NTFS filesystem that is visible in Windows as well as Linux. For good measure I thoroughly formatted the drive a second time using the option in the File Explorer menu system.

Now when I check my drive in Windows it appears as it should; one large partitions with (almost) the whole capacity of the USB available.

A lot of people have written on the balenaEtcher forums about this problem, blaming the software for destroying their USB drives. This is not the case as the drives can be fixed, but it would be nice if balena addressed this issue by providing some kind of tool for restoring a drive to its original state.