May 15, 2009 \\ 13:29

Media is write protected

Today I faced a problem with two of my partitions. I wanted to save a file to a folder, like I usually do, but instead of simply putting the file there, Windows complained that it’s unable to complete the operation with the message “The media is write protected“. I started to look into the problem, and found out soon that for some reason, every folder on that special partition had the same problem, other partitions though worked still fine. Checking out the security permissions, I figured out, that the owner-information was different compared to other partitions and folders – but of course Windows didn’t let me change anything (“An error occurred while applying security information to … The media is write protected.“).

As restarting the computer didn’t change anything, I looked up the problem at Google and found a lot of other users with a similar issue like mine. It seems, this is problem with Windows Vista, Windows 7 and also Windows XP, which might occure when you use the 64bit version, and can’t be really reproduced. It’s kind of a random thing, that appears out of nowhere. Some state that it has something todo with backup-software blocking the disk, others say it might be virus-protection or corrupt fileheader.

open diskpart

open diskpart

Anyways, I figured out a solution that worked perfectly and doesn’t even need to restart the system, using the tool Diskpart, that’s included per default since Windows Vista. Therefore you have to open a command prompt (WIN + R), type diskpart and hit Enter.

remove readonly flag

remove readonly flag

Next, you’ll need to figure out which volume number the partition has that’s protected. To do this, use the command LIST VOLUME. Now, switch to the required partition with SELECT VOLUME #, where # is the ID of the volume. Finally, simply remove the protection with ATTRIBUTES VOLUME CLEAR READONLY. That should do the trick!

More like this

We currently have

8 Responses

to this article. Want to

say something

yourself?

  • Jarretf says:

    Unfortunately, this didn’t work for me. I am running the Win 7 RC. Partition still write protected, but the DISKPART application shows it as “READ-ONLY: NO”. :-(

  • Jarretf says:

    Ok, it DID work! Apparently you have to specify the drive letter, as you did in your screenshot. The first time I tried it, I had “SELECT VOLUME 7″ and it failed. After posting my first reply, I tried the drive letter “SELECET VOLUME D”, and it worked! MANY THANKS!!!!

  • Mikey says:

    Every time I reboot my machine my external drive keeps getting set to read only. Is there any way to prevent it from happening over and over again?

  • Jace says:

    I’m not sure if this will work 100%, but it worked for me.

    1. Open an elevated command prompt (right-click and run cmd.exe as an administrator)
    2. If your backup drive is E:, type the following (change the drive letter to your affected drive): chkdsk /f E:
    3. chkdsk should run for a few seconds and then report – “Insufficient disk space for CHKDSK to recover lost files”
    4. Repeate step 2 again, this time Chkdsk succeeded on my system and resolved the issue for me

  • Jack says:

    I’m having the same problem. I used diskpart and that did the trick for me. I have not rebooted yet to see if it will keep the settings. Microsoft has to know about this problem….?

  • Very nice blog, your article is interesting, i have bookmarked it for future referrence

  • Sunday says:

    this solution works perfect, thanks for screen shot, that help a lot, bookmarked,

Leave a Reply

Comments may be held for moderation. If your comment does not appear immediately, do not repost. I reserve the right to remove any inappropriate or off-topic comments. Want other to know who you are? Register a Gravatar.

  •  
IMG_8496IMG_8493IMG_8491

Subscribe

Stay updated on my meandering thoughts & activities via RSS (Syndicate).


Meta