Re: Cannot format USB flash driver using Gparted

Either the pendrive is failing (which is rather common with such devices), or the partition table and other general information is bad. In the latter case it might help to wipe the first megabyte (not only the first 512 bytes). This can be done directly with dd as adviced by oldfred (but slightly modified),

Either the pendrive is failing (which is rather common with such devices), or the partition table and other general information is bad. In the latter case it might help to wipe the first megabyte (not only the first 512 bytes). This can be done directly with dd as adviced by oldfred (but slightly modified),

I tried that command, but still, I gparted says "File system unallocated".
When I try to create new file system it says "No partition table found on device /dev/sdb".
If I want to create new partition table (msdos) it says: "Libparted bug found! Input/output error during write on /dev/sdb"

Re: Cannot format USB flash driver using Gparted

I tried that command, but still, I gparted says "File system unallocated".
When I try to create new file system it says "No partition table found on device /dev/sdb".
If I want to create new partition table (msdos) it says: "Libparted bug found! Input/output error during write on /dev/sdb"

I think you have done what is possible with gparted now. It seems that gparted cannot write to that device. But you can still see it as /dev/sdb (as read only). It is typical of a failing flash drive (it remains read-only after writing does not work. The next step is that it cannot be read either).

But the problem might also be co-operation with that particular USB port or with the computer, so try in another USB port and try in another computer, if you are able to create a partition table and make a file system ('format' it).

Re: Cannot format USB flash driver using Gparted

Originally Posted by sudodus

I think you have done what is possible with gparted now. It seems that gparted cannot write to that device. But you can still see it as /dev/sdb (as read only). It is typical of a failing flash drive (it remains read-only after writing does not work. The next step is that it cannot be read either).

But the problem might also be co-operation with that particular USB port or with the computer, so try in another USB port and try in another computer, if you are able to create a partition table and make a file system ('format' it).

Tried other usb port but same. I guess I will try to somehow test it on another linux machine

Re: Cannot format USB flash driver using Gparted

If you use the dd procedure to create an Intaller, it does not use standard partition table like all the other methods. And then because partition table does not exist partition tools see random data or think it is corrupted.

Sometimes then just writing 0 to MBR to totally erase boot loader and partition table info works.
Do not use this if trying to recover any data from old partitions on flash drive.

Re: Cannot format USB flash driver using Gparted

Originally Posted by oldfred

If you use the dd procedure to create an Intaller, it does not use standard partition table like all the other methods. And then because partition table does not exist partition tools see random data or think it is corrupted.

Sometimes then just writing 0 to MBR to totally erase boot loader and partition table info works.
Do not use this if trying to recover any data from old partitions on flash drive.

Re: Cannot format USB flash driver using Gparted

Originally Posted by oldfred

As posted before, it just may be dead. They do not last a long time and may just fail at anytime.

But it was good usb until I started reformatting with gparted. If it's indeed dead then it's only because I did something, but again, what I did is just regular gparted or Windows xp format commands, I didn't even use command line.

Re: Cannot format USB flash driver using Gparted

I have been doing such operations (with gparted, dd, etc) thousands times. They do not destroy the drive. They may destroy data by overwriting the partition table or (parts of) some partition, but the drive itself survives. As said before, pendrives have limited lifetime, and this one just happened to die while you were running these commands.

-o-

This is what I think; it is hard to be sure when I cannot run the different operations myself. We have to rely on verbal conversation, and we might misunderstand each other.