MicroSD card is set to Read-only state. How can I write data on it?

Two possibilities, first is that being a hardware thing, as micro SDHC have a little notch you can easily notice which matches another notch in the reader and that basically just enables it in read-only mode. That you can't change, just try to use another reader or you could put a piece of silicon or tape on notch, easiest thing is to use another reader.

Second possibility is that being a file permission issue, in which case you can do the following : In terminal, use these commands:

gksudo nautilus

This will launch nautilus in root shell and bypass all permissions. OR:

sudo fdisk -l

This will give you a list of the drives on your system, figure out which drive it is in the list, easiest way is to look for the blocks as this is the space. It will probably be /dev/sdb or /dev/sdc, then

sudo chown -hR <your username> <the SDHC drive, /dev/sdb for example>

this will change ownership of the drive to you. OR:

sudo chmod -R 777 <the SDHC drive, /dev/sdb for example>

Though if you just execute the first command sudo nautilus it will save you all this trouble, but you'll have to do it every time you use the SDHC.

If all of this doesn't work, use this command :

sudo mount --options remount,rw <the SDHC drive, /dev/sdb for example, find it using fdisk -l>

If there's anything you don't understand just comment.


Not able to get it try this login to root mode.. open terminal type

hdparm -r0 /dev/sdc

than your write protection bit or say ur read only bit will be set to ZERO and now you type

mount /media/ur_pen_drive_name(like mine is HSR)/ -o remount,rw

And that's it.... remember windows can't do this because there is a virus in your pen drive ok... now it doesn't any permission to be changed so if you find any .exe file not getting deleted from your pd just do the above two step and than you'll be able to delete it...


Physical write protection

For those who never used SD cards before, you have to move the LOCK switch to the unlocked position:

Image attribution.

It is analogous for a micro SD adapter with a MicroSD inside: the dongle is on the adapter:

Related: https://raspberrypi.stackexchange.com/questions/8225/trying-to-image-sd-card-not-working-read-only-file-system

Tags:

Ram

Sd Card