If that fails, try the following, instead. Replacing X with your actual USB drive letter, type the following and then press enter ĭd if=/dev/zero od= X: count=1 bs=4096 -progress Next, we will wipe out the partition table and leading filesystem information.įor Windows users using dd.exe.
Several methods to help you restore a USB flash drive back to original state with full capacity.
For exFAT, (if using Ubuntu or Debian), type apt install exfat-utils and then type mkfs.exfat /dev/sd x1 (replacing xwith your drive letter).For Fat32, type mkfs.vfat -F 32 /dev/sd x1 (replacing xwith your drive letter).The last step is to create the fat32 or exFAT filesystem. Type umount /dev/sd x1 (replacing x with your drive letter).Ĭ.Type w to write the new partition information to the USB key.Press enter again to accept the default last sector.Next press enter to accept the default first sector.Type 1 to make this the first partition then press enter.Then type p to make this partition primary then press enter.Next we need to create the new partition. (fdisk should automatically select the second partition).ī. Then type d to proceed to delete another partition, if necessary.Type 1 to select the 1st partition then press enter.Next type d to proceed to delete a partition.Then type fdisk /dev/sd x (replacing x with your drive letter).Type fdisk -l and note your USB drive letter.Open a terminal ctrl+alt+t and type sudo su.First we need to delete the old partitions that remain on the USB key.
The following manual tasks to restore a USB drive can be performed from a Linux terminal window.Ī. Restoring a USB key to its original state using Linux