2

I'm trying to format a pen drive using mkfs, but it fails with: Read-only file system. Here is what I have tried so far:

$ sudo hdparm -r0 /dev/sdb1

/dev/sdb1:
 setting readonly to 0 (off)
 readonly      =  0 (off)
$ umount /dev/sdb1
$ sudo chmod 777 /dev/sdb1
$ sudo mkfs -t vfat /dev/sdb1
mkfs.vfat 3.0.13 (30 Jun 2012)
mkfs.vfat: unable to open /dev/sdb1: Read-only file system

What should I do?

  • poss dupe http://askubuntu.com/q/185815/46312 – Ringtail Jan 10 '13 at 17:39
  • 1
    Some pen drives have a readonly/readwrite switch. Have you checked it? Also, after issuing the mkfs command, could you please run dmesg | tail and paste the output inside your question? Thanks! – Andrea Corbellini Jan 10 '13 at 18:01

0 Answers0