1

So, I have an old Sandisk Cruzer Edge 4GB USB drive, And I know how to format the usb, so I did what works for all USB drives, first, I used fdisk -l to find my USB's file-system. Heres what came up:

Disk /dev/sdb: 4004 MB, 4004511744 bytes
124 heads, 62 sectors/track, 1017 cylinders, total 7821312 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0000000

Disk /dev/sdb doesn't contain a valid partition table

So, I'm going on, I successfully unmounted the USB, then ran the command sudo mkfs.ext4 /dev/sdb I get the error:

user@user:~$ sudo mkfs.ext4 /dev/sdb
mke2fs 1.42.9 (4-Feb-2014)
/dev/sdb is entire device, not just one partition!
Proceed anyway? (y,n) y

/dev/sdb: Read-only file system while setting up superblock

Please help? Thanks for any help!

PS: My USB doesn't show up in GParted, so don't tell me to try that please :)

Mitch
  • 109,787
Redrield
  • 362
  • 1
  • 2
  • 10

2 Answers2

1

When a pendrive or memory card is read-only

  • On some pendrives and on many memory cards there is a small mechanical switch for write protection, that can toggle between read/write and read-only. You might have set it read-only without intention.
  • Reboot the computer and try again to wipe the first megabyte with mkusb.
  • Try other USB ports and another computer.
  • If you still cannot wipe the first megabyte of the drive, and the drive is read-only, it is 'gridlocked', and the next stage is that it will be completely dead.

Pendrive lifetime

But there is still hope, because this symptom can also be caused by a severely damaged partition table. Try to wipe the first megabyte (overwrite with zeros). If this works, you can use gparted or another tool to create a partition table, and after that partitions again.

mkusb

wipe the first megabyte

If this does not work, the pendrive is damaged beyond repair (for normal users).

There are more details at the following link,

Can't format my usb drive. I have already tried with mkdosfs and gparted

sudodus
  • 47,684
0

It looks like this could be a hardware bug of the SanDisk Cruzer Edge. A sudo cfdisk /dev/sdb should never return Opened disk Read-Only - You have no permission to write. Quick googling shows that this is a common problem. If you still have warranty, I would try to exchange the Cruzer.

Other related questions:

https://superuser.com/questions/661108/how-to-remove-write-protection-from-sandisk-cruzer-switch-pen-drive

noleti
  • 4,103
  • 28
  • 27