-   Linux - General (
-   -   I need to reformatt a usb that gives me: Read-only filesystem (

tallmtt 03-24-2007 03:19 PM

I need to reformatt a usb that gives me: Read-only filesystem
I am coming to believe my problem is unique!

I was given a usb disk (64mb) by an organization. They were jerks and modified it slightly.

When you insert it in linux, it is automatically loaded as 2 disks (usb1, usb2) where usb1 is a directory with a piture, Autorun.inf, and a binary file called browserrun.exe. In windows this partition loads automatically as a cdrom and displays the picture. I want to remove the partition.

I umount the partition and fdisk it (fdisk /dev/sda) and I get:

"You will not be able to write the partition table."

and the message is correct :cry:

I have tried remounting with " -o rw " but get the message:

"mount: block device /dev/sda is write-protected, mounting read-only"

The filesystem is vfat.

Please help me!!! I just want to delete the partition and enlarge the other one.

uselpa 03-24-2007 03:34 PM

USB disks often have some kind of button which you can push or slide to write-protect them.

tallmtt 03-24-2007 10:21 PM

Thanks for your quick reply, this particular usb disk does not have a switch. In fact, the one partition loads up read-only, and the other loads up read-write.

thanks anyways - Any other ideas???

Junior Hacker 03-24-2007 10:58 PM

Stick the USB drive in, it should show up in fstab or if you have KDE you may also have kdiskfree which will tell you which device it is, such as /dev/sda if you have ATA hard drive, /dev/sdb if you have one sata drive. Once you know which device it is, even if it says /dev/sda1 and /dev/sda2 for the two partitions, you know it is /dev/sda.
From a terminal, you can use dd to wipe it with zeros, then you will need to re-partition and re-format.

dd if=/dev/zero of=/dev/sda conv=notrunc

This should wipe all info including write protection and MBR.

tallmtt 03-24-2007 11:47 PM

That sounds promising, I tried a dd command I found earlier and it did not work. Will try it in the morning.

The one reservation I have is that it loads up with under two devices (sde, sdf1). It is the sde that is the problem. I think if I can wipe it, I will be able to do what I need to with the drive - so I'm crossing my fingers :)

Thanks, I will update my results.

Junior Hacker 03-25-2007 12:16 AM


That put me in a spin, it's listing it as two different devices, not two partitions. There must be some customizing in the MBR.

dracolich 03-26-2007 05:31 PM

Sounds to me like one of the "smart" drives, like U3. If that's the case the only way to remove the read-only partition is with a format utility that you should be able to get from the disk vendor's website. Also, in this case only the first partition would be read-only. The second partition should be able to mount as read-write and have all but a few MB of the total capacity.

tallmtt 07-09-2007 11:09 AM

I don't know anything about "smart" drives, but with prices so low this "free" usb drive of only 64MB is too annoying to keep messing with. Thanks for all of your help

All times are GMT -5. The time now is 12:09 PM.