Summary: In this blog, we’ll try different methods to fix the error “Windows cannot run disk checking because it is write protected.” You can also try using a professional data recovery software like Stellar Data Recovery Professional to recover your inaccessible data due to this error.
The error message “Windows cannot run disk checking because its write protected” may appear when you’re trying to repair a disk error using the CHKDSK (Check Disk) command in Windows.
The error is caused due to corruption in the volume or when the volume appears as “Read Only”. Let’s look at some possible resolutions to fix the error.
Method 1: Remove Write Protection using Command Prompt
This command removes any write protection status by unmounting the drive/volume, USB, or SD card in question.
1. Go to Search box in your Windows and type cmd. A dialog box will open. Choose the option, Run as an administrator.
2. Enter chkdsk E: /f /r /x in the command prompt window and press Enter. Replace “E” with the letter of your specific drive/volume.
Now try to rerun CHKDSK program again to check if the error persists.
Method 2: Use Diskpart to remove Write Protection
Diskpart is a function that can help you remove the “read-only” attribute from your hard drive. Use the steps below to use this feature.
1. Go to Search box in your Windows and type cmd. A dialog box will open. Choose the option, Run as an administrator.
2. A code window will open. Enter the command as stated below
list disk
select disk X (In place of “X”, write the disk letter of the drive/USB/SD card in question)
attributes disk clear read-only
On running the command, you should get a message “Disk message cleared successfully.” If you see that message, then exit the screen and rerun the CHKDSK program.
If this still doesn’t resolve the error, try the next method.
Method 3: Use Registry Editor to clear Read-Only
You can also clear the “Read-only” attribute of the drive by using the Registry Editor. Follow the steps below:
Step 1. Enter Regedit by pressing Windows+R.
Step 2. Navigate to: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\StorageDevicePolicies.
Step 3. Look for the WriteProtect key. Right-click on it and set the value as “0”.
By using one of the above methods, you should be able to resolve the error. But, there might be cases when the file system is so corrupt that it would be impossible to fix the error. To make the disk reusable again, we recommended to wipe the data from the disk. Before wiping though, you should recover all existing files so that you do not lose any valuable/sensitive information.
This is where a data recovery software comes into the picture.
Recover data from a corrupted drive using a Data Recovery Software
A data recovery software works by recovering your data from various loss scenarios, including from a corrupted drive. One of the prominent data recovery software is Stellar Data Recovery Professional for Windows. It uses advanced techniques to scan and securely extract all your data. In the scenario described in the blog, data recovery software will allow you to recover your valuable data before you wipe the drive clean. These two steps, recovery of data and then wiping the drive will let you reuse your hard drive without losing any data.
How to use Stellar Data Recovery to recover your data from a corrupted drive?
1. Download and install Stellar Data Recovery Professional software.
2. Next, select the type of data you wish to recover.
3. Choose the drive in your PC from where you want to recover the data.
4. Once you have selected the drive, click Scan. You can also preview the files before recovering at the time of scanning.
5. After scan completion, click Recover and choose a location to save the recovered files. (See Image 5)
6. Finally, click ‘Start-Saving’ to save the data. (See Image 6)
Wiping the drive clean
Once you have recovered your data, the next step is to erase your drive to make it reusable again. The most effective way to permanently and securely erase the files is to use a professional file erasure software like Stellar File Eraser. Stellar File Eraser is a professional DIY tool, designed to erase files permanently from your drive.
Read this article for a step-by-step guide on permanently erasing files from a drive using Stellar File Eraser software.
Conclusion
The error “Windows cannot run disk checking on this volume because it is write protected” can occur due to a variety of reasons. We hope that the methods described in the blog help you resolve the error. If the remedies don’t work then it is advisable to use a data recovery software like Stellar Windows Data Recovery Professional and restore the computer to an earlier date.
Was this article helpful?
YES0
NO
Encountering an error while attempting to run a disk checking command (CHKDSK) on Windows often results in the command failing to execute properly. This issue typically occurs when the disk is flagged as “write-protected” or when Windows cannot access the disk, indicating that the system is unable to perform the check due to restrictions or corruption.
The most frequent cause is a write-protection attribute set on the drive, either through a physical switch, a corrupted file system, or registry settings.
Other common reasons include file system errors that necessitate a restart to fix, disk corruption, or the need for administrative privileges.
This error can also occur on memory cards. If that’s the case, you can easily remove the write protection using the lock on the memory card.
1. Clear Read Only Attributes
You can easily clear the Read-Only attribute by using the diskpart utility, which allows users to manage disks efficiently.
- Click Start Menu and type Command Prompt.
- Right-click on the command prompt and then select Run As Administrator.
Running Command Prompt As Administrator - Once the terminal is launched, type the following command to use the diskpart utility:
diskpart
- After entering diskpart, type the following command to list all your volumes:
list volume
- Select the volume causing the error by replacing # with the volume number:
select volume #
Using Diskpart Volume - Before making any changes, check the current attributes:
attributes volume
- If the volume is marked as Read-Only, clear the Read-Only mode:
attribute disk clear readonly
Leaving Read Only Mode - If you’re dealing with the entire disk, list all the disks and select the appropriate one:
list disk select disk #
- Check the current disk attributes:
attribute disk
- If the disk is marked as Read-Only, clear the Read-Only mode:
attributes disk clear readonly
- After that, type the following command to check the current state of the disk. If the Read Only mode value is No, the disk is no longer write-protected:
attribute disk
Checking Disk Attributes - After that, run the disk-checking commands to see if the error is fixed.
2. Remove Write Protection Via Registry Editor
You may also try removing the write protection using the Registry Editor. The Registry Editor is a database for the operating system to store and manage all the tasks. This error might not appear after disabling the write protection using the Registry Editor.
Note: Please make a backup of your registry before making any changes to it, as improper changes can cause instability issues on your system. Follow our detailed guide on how to backup and restore Registry in Windows.
- Press Windows + R on the keyboard to open the Run program.
- Type Regedit and click OK.
Opening Registry Editor - Once the Registry Editor is launched, navigate to the following path:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\StorageDevicePolicies
Note: You can paste the following path in the address search bar for faster navigation.
Navigating to a Path in the Registry Editor - If the Storage Device Policies key is not there, create one under Control.
- Right-click Control, hover over New, and then click on Key.
Making A Registry Key - Once the entry is created, name it StorageDevicePolicies.
- Right-click on the right pane, hover over New, and then click DWORD (32-bit) Value.
Creating A Subkey - Name it Writeprotect, then double-click on it and change its value data to 0.
- When done, click OK.
Changing Value Data to 0 - Restart your computer and run the disk-checking commands to see if the error persists.
3. Repair Disk Errors
If you have any disk errors in your target drive, it can lead to this issue. However, if you use some commands to ensure there is no disk error, then you can consider other potential solutions. Regardless of checking the drive for bad sectors, we have done everything that can fix this issue.
To check for disk errors, use chkdsk, a command-line utility that allows users to check for bad sectors and verify the integrity of system files in the target volume.
- Press the Windows key and type command prompt.
- Right-click on the terminal and choose Run As Administrator to launch with administrative privileges.
Opening Command Prompt As Administrator - Once it is launched, type the following command to check for disk errors and bad sectors:
chkdsk D: /f /r /x
Note: Make sure to replace D with the faulty drive.
/f: Fixes errors on the disk. /r: Locates bad sectors and recovers readable information. /x: Forces the volume to dismount first if necessary.
Important: The
/x
parameter forces a dismount, which should not be used on the root partition (usually the C: drive) or other active system partitions because it can interrupt system operations and cause instability. Always ensure you have saved and closed any open work on the drive before using this parameter.Running CHKDSK - If errors are found, the utility will automatically fix them, so don’t worry.
- Once done, check if the error is still occurring.
If none of the methods have successfully removed the write protection from your drive, there are three potential factors that could be causing this issue:
- Encryption: Your drive might be encrypted. If this is the case, you will need to unlock the drive using the appropriate decryption key.
- Third-Party Software: The write protection may have been applied by a third-party application. To remove the write protection, you will need to utilize the same software that imposed it.
- Corruption or Physical Damage: It is also possible that your drive is corrupted or physically damaged.
If one of these scenarios applies to your situation, follow the corresponding solution mentioned above. However, if none of these methods resolve the issue, it may be necessary to consult a local data recovery center to retrieve your data.
Kevin Arrows
Kevin Arrows is a highly experienced and knowledgeable technology specialist with over a decade of industry experience. He holds a Microsoft Certified Technology Specialist (MCTS) certification and has a deep passion for staying up-to-date on the latest tech developments. Kevin has written extensively on a wide range of tech-related topics, showcasing his expertise and knowledge in areas such as software development, cybersecurity, and cloud computing. His contributions to the tech field have been widely recognized and respected by his peers, and he is highly regarded for his ability to explain complex technical concepts in a clear and concise manner.
Как перейти от Waterfall к Agile
EggHead 06.05.2025
Каскадная модель разработки Waterfall — классический пример того, как благие намерения превращаются в организационный кошмар. Изначально созданная для упорядочивания хаоса и внесения предсказуемости. . .
Оптимизация SQL запросов — Продвинутые техники
Codd 06.05.2025
Интересно наблюдать эволюцию подходов к оптимизации. Двадцать лет назад всё сводилось к нескольким простым правилам: «Избегайте SELECT *», «Используйте индексы», «Не джойните слишком много таблиц». . . .
Создание микросервисов с gRPC и Protobuf в C++
bytestream 06.05.2025
Монолитные приложения, которые ещё недавно считались стандартом индустрии, уступают место микросервисной архитектуре — подходу, при котором система разбивается на небольшие автономные сервисы, каждый. . .
Многопоточность и параллелизм в Python: потоки, процессы и гринлеты
py-thonny 06.05.2025
Параллелизм и конкурентность — две стороны многопоточной медали, которые постоянно путают даже бывалые разработчики.
Конкурентность (concurrency) — это когда ваша программа умеет жонглировать. . .
Распределенное обучение с TensorFlow и Python
AI_Generated 05.05.2025
В машинном обучении размер имеет значение. С ростом сложности моделей и объема данных одиночный процессор или даже мощная видеокарта уже не справляются с задачей обучения за разумное время. Когда. . .
CRUD API на C# и GraphQL
stackOverflow 05.05.2025
В бэкенд-разработке постоянно возникают новые технологии, призванные решить актуальные проблемы и упростить жизнь программистам. Одной из таких технологий стал GraphQL — язык запросов для API,. . .
Распознавание голоса и речи на C#
UnmanagedCoder 05.05.2025
Интеграция голосового управления в приложения на C# стала намного доступнее благодаря развитию специализированных библиотек и API. При этом многие разработчики до сих пор считают голосовое управление. . .
Реализация своих итераторов в C++
NullReferenced 05.05.2025
Итераторы в C++ — это абстракция, которая связывает весь экосистему Стандартной Библиотеки Шаблонов (STL) в единое целое, позволяя алгоритмам работать с разнородными структурами данных без знания их. . .
Разработка собственного фреймворка для тестирования в C#
UnmanagedCoder 04.05.2025
C# довольно богат готовыми решениями – NUnit, xUnit, MSTest уже давно стали своеобразными динозаврами индустрии. Однако, как и любой динозавр, они не всегда могут протиснуться в узкие коридоры. . .
Распределенная трассировка в Java с помощью OpenTelemetry
Javaican 04.05.2025
Микросервисная архитектура стала краеугольным камнем современной разработки, но вместе с ней пришла и головная боль, знакомая многим — отслеживание прохождения запросов через лабиринт взаимосвязанных. . .
Position: Resource — Disk Utilities — Fixed: Windows Cannot Run Disk Checking on This Volume Because It Is Write Protected
CHKDSK is a free command-line tool built in Windows operating system, and it is provided to help users check file system and file system metadata of a volume for either logical or physical errors. The single command «chkdsk» shows the status of the volume being scanning, and if it is used with parameters like /f, /r, /x, or /b, it will fix errors on the volume.
The error «The type of the file system is NTFS. Windows cannot run disk checking on this volume because it is write protected» occurs when the user attempts to check and repair errors on a storage device, for example a hard drive, using the CHKDSK command. If the disk to be checked is write-protected, it is likely to end up with the error message.
What causes the error? Much of the time the error occurs due to following reasons:
- The drive is write-protected: When a drive is set as write-protected, also called read-only, which means you can only view content on the drive. In other words, you cannot make changes, for example, reformatting, remove data, edit files, etc. are not allowed.
- Corrupted drive: The drive is damaged due to either logical or hardware errors, such as, bad sectors, virus attack, internal components are damaged, etc.
How do I run chkdsk on write protected and how do I unprotect my hard drive? Chkdsk command cannot run on storage device before write protection is disabled. Next, we’ll discuss 5 troubleshoots regarding how to clear write protection as well as how to rescue data from read-only hard drives. Before executing following fixes, it is recommended to restart computer first, which can refresh the computer and get rid of corrupted temporary data that may has something to so with the problem.
Important: some of the solutions listed below will cause data loss, and you should backup or recover data in advance if you do not want to lose them. As to restoring files from write-protected disks, skip to: Recover Files From Write-Protected or Corrupted Hard Drive
Solution #1: Remove Write Protection Using Diskpart
Step 1. Type «Command Prompt» in the searching box next to Start menu. Right-click «Command Prompt» in searching result and choose «Run as administrator».
Step 2. In Command Prompt, type diskpart and press Enter key.
Step 3. Type following commands one by one, and press Enter key after each command.
List volume
Select volume # (replace # with the number of the drive you want to remove write protection)
attributes disk clear readonly
When you see the message «Disk attributes cleared successfully», you can run chkdsk to see if it still reports the error. If you are not good at using command lines, you can use third-party partition manager software DiskGenius Free Edition to do the task.
Solution #2: Remove Read-only Status Using DiskGenius Free Edition
Step 1. Install and run DiskGenius Free edition on your computer and connect the hard drive.
Step 2. Select the drive that is write-protected, click Disk > Change Device State. Then you will see the «Read-only» option is selected, click it to cancel the selection.
Step 3. Click OK to confirm the action and the read-only state will be disabled.
Solution #3: Clear Write Protect in Registry Editor
Step 1. Press Windows and R keys to open Run dialog box. Type regedit and click OK button to open Windows Registry Editor.
Step 2. Navigate the entries and locate StorageDevicePolices via: Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\StorageDevicePolicies.
Step 3. Double-click the «WriteProtect» key and change its value from 1 to 0.
Solution #4: Repartition the hard drive
Since the volume you want to run disk checking is write-protected, you can simply remove it and recreate a new one. In case all volumes on the hard drive are in the same status, you can simply repartition the hard drive. The disk repartitioning process removes all current partitions and creates new ones. Moreover, it will format all newly created partitions. Therefore, you will lose all files on the hard drive. If you want to keep files, then backup files in advance. DiskGenius provides the function «Quick Partition» which is able to repartition a disk rapidly and easily.
Step 1. Launch DiskGenius Free Edition, select the hard drive you want to clear write protection, and click Quick Partition button.
Step 2. Set partition table type to either MBR or GUID and select the number of partitions to be created. Then click «OK» button.
Step 3. Click «Yes» to start the repartition task.
Solution #5: Check and Repair Bad Sectors for the Drive
DiskGenius Free Edition is a good alternative to check and repair bad sectors on hard drive and USB drive when Windows disk checking cannot run. Let’s get to know how to check bad sectors with DiskGenius.
Step 1. Run DiskGenius, select the drive you want to check bad sectors and click Disk > Verify Or Repair Bad Sectors.
Step 2. Click «Start Verify» button and the software starts to scan the disk.
The above are five effective ways of removing write protecting on hard drives and USB drives. Most often, the error «Windows cannot run disk checking on this volume because it is write protected» will be fixed by one of the solutions. If disk checking still cannot on the disk, you will have to pay attention whether the disk is physically damaged. When the storage device is corrupted due to hardware damages, it is hard to repair it with certain software, and you need to send it to a professional repair center or the manufacturer of the hard drive.
As end users, undoubtedly, we are more concerned about files stored on the disk instead of the disk itself. Hence, it is important to know how to retrieve files from hard drives or USB drives that are write-protected, corrupted or even formatted. When it comes to data recovery, DiskGenius will be a good assistant, for it supports to perform RAW drive recovery, format recovery, deleted file recovery, lost partition recovery and so on.
How to Recover Files from Write-Protected or Corrupted Hard Drive?
Step 1. Download and install DiskGenius on your computer. Right-click on the volume where you want to restore data and choose «Recover Lost Files».
Tip: It is possible that all files of this volume are displayed in DiskGenius after the software is launched. In that case, you can begin copying files to another drive directly without performing rest steps.
Step 2. Click «Start» button to let the software scan the selected disk area and look for lost files.
The scanning process may take a while if the capacity to be scanned is very large or the disk has bad sectors. Anyway, what you need to do is just waiting with patience.
Step 3. Preview files to check recovery quality.
Once the scanning completes, you can preview files (double-clicking a file opens the preview window) and check if files to be recovered are correct. File preview helps to evaluate whether files are corrupted prior to final recovery.
Step 4. Register the software and copy lost files to another drive.
By way of file preview, you have a clear understanding of the recovery quality. If you are satisfied with the scanning result, then register the software with a license key and start copying files.
FAQs regarding cannot run disk checking
1. How do I run chkdsk on write protected?
Users are not allowed to perform write-related action to the write-protected drive, to run chkdsk on such drives, you need to remove write protection first. A couple of methods can remove the protection for you, just refer to solutions described above.
2. Can’t run chkdsk because drive is locked?
To run chkdsk successful, you just need to unlock the drive. First, restart computer to refresh the Windows operating system, and then run command «chkdsk E: /f /r /x» in Command Prompt.
3. How do you fix Windows can’t check the disk while it’s in use?
The error «chkdsk cannot run because the volume is in use by another process» tends to appear when the device you want to run disk checking is used by other program. To get rid of the error, you can try running chkdsk in Windows PE. With the help of DiskGenius Free edition, you can easily reboot to WinPE from Windows.
4. How do I unprotect my hard drive?
Write protection prevents hard drive from being erased or written, and the feature can be enabled by users manually or by virus. To unprotect hard drive and other USB drives, you can try these solutions:
- Use DiskGenius to remove read-only attribute
- Execute «attributes disk clear readonly» command with Diskpart
- Remove write protection in Registry Editor
5. How do I fix Diskpart failed to clear disk attributes?
The error «Diskpart failed to clear disk attributes» appears in Command Prompt when the command «Attribute disk clear readonly» fails to remove the write protection on the selected disk. Refer to this guide to fix the error: Six Solutions to DiskPart Virtual Disk Service Error
Conclusion
A variety of reasons can give write to the error «Windows cannot run disk checking on this volume because it is write protected», and we need to try different solutions to get it fixed. Since some of the solutions will cause data loss, it is highly recommended to create backups or perform data recovery in advance. Should you need any help on hard drive data recovery, feel free to contact our technical support team.
Quick links
- Fix «Windows Was Unable to Complete the Format» in Windows 10/8/7
- Fixed: You Need to Format the Disk in Drive Before You Can Use It
- How To Fix «The Disk Is Write Protected» Error on USB Drives?
- The Type of The File System Is RAW. CHKDSK Is Not Available for RAW Drives