AVG Signal Blog Performance Hardware How to Scan and Fix Hard Drives with CHKDSK Commands in Windows
Signal-How-to-scan-and-fix-hard-drives-with-CHKDSK-in-Windows-Hero

What is CHKDSK?

CHKDSK (check disk) is a Windows utility designed to scan for and repair system errors. It checks whether a file’s size, location, and other system information matches the data that's actually on the disk. CHKDSK also looks for parts of the hard drive that may corrupt your data.

This article contains:

    CHKDSK lets you check a hard drive for errors in Windows 10, specifically the kind of errors that arise when files aren't where they're supposed to be. This issue is a common reason why your PC gets slower over time.

    How to run CHKDSK in Windows 10

    There are multiple ways to run CHKDSK in Windows 10, even when your PC doesn't seem to be working. If you have to repair your Windows 10 hard drive in an emergency, CHKDSK might be the answer.

    Here are three CHKDSK options you can try:

    Run CHKDSK from your computer

    You can use the CHKDSK utility from within Windows, and it'll scan your drive for errors. Here’s how to run CHKDSK in Windows 10:

    1. Type chkdsk in the search box in your taskbar.

       A picture of a taskbar with "check disk" typed in, and the user has right clicked the check disk application and is highlighting the option "Run as administrator."
    2. Right-click chkdsk and choose Run as Administrator.

    This method may cause CHKDSK to run without showing you the results. For more detailed and customized results, try running CHKDSK from the command prompt.

    Run CHKDSK from Command Prompt

    The Command Prompt is a useful tool that lets you execute commands in Windows — when you directly tell Windows what to do. If you’re not careful, this can result in additional complications, so make sure to follow these steps closely.

    Here’s how to use Command Prompt to check your disk:

    1. Type cmd (or command prompt) in the search box in your taskbar.

      A picture of a taskbar with "command prompt" typed in, and the user has right clicked the command prompt application and is highlighting the option "Run as administrator."
    2. Right-click Command Prompt and select Run as Administrator.

      A picture of the command prompt, with "chkdsk" typed into the input.
    3. Type chkdsk and hit Enter. This command will make the CHKDSK utility scan for problems without making changes.

      A screenshot of command prompt with "chkdsk D: /f" entered in the prompt.
    4. To run CHKDSK on a drive other than your C drive, specify the volume right after chkdsk. For example, check your D drive by typing chkdsk D: /f.

      Keep reading to find out what “/f” means and how to make CHKDSK repair corrupted files. But if there are no problems at this stage, you don’t need to do anything further.

      An example of results from running chkdsk. The results say that no problems were found.

    The best part about Command Prompt is that it’s been consistently used across all Windows operating systems. Whether your computer is brand-new or 20 years old, you can use the same commands.

    Run CHKDSK from Windows 10 Installation Disk

    Your Windows 10 installation disk is a partition of your hard drive isolated from the rest of your data. If you can't access your main hard drive, the installation disk will let you install a fresh version of Windows if necessary. It should be accessible as long as you can turn your computer on. 

    If you can't access your main drive, running CHKDSK from here might do the trick. Here's how to run CHKDSK from your Windows 10 installation disk before boot:

    1. Turn on your computer and repeatedly tap F8 before the Windows logo shows up.

    2. When prompted, click Repair Your Computer.

    3. Click Troubleshoot and then select Advanced Options.

    4. Click Command Prompt. You can use this command prompt just the same as any other, and you can run CHKDSK on your Windows drive before it boots.

      A screenshot of the advanced options you can access when you boot from Windows 10 Installation disk.

    CHKDSK should identify and remove bad sectors or corrupted data so that your computer will work normally again. 

    Now that you know how to run CHKDSK, you have a new tool to keep your computer and hard drive in tip-top shape. But what about other types of necessary maintenance?

    AVG TuneUp is a comprehensive maintenance and optimization tool that ensures your PC runs smoothly at all times. No task is left behind, whether it's clearing the cookies and cache from your browser or finding corrupted data as soon as possible. Why bother with poking around in the Command Prompt when you can have an app that does it all automatically.

    Why do I need to use CHKDSK?

    You need to use CHKDSK when a boot error occurs. Corrupted data can break Windows, and CHKDSK can find those bad files and let Windows install a fresh copy in a new location. You can also use CHKDSK to prevent data loss.

    How does data go missing or get corrupted in Windows?

    Ruined parts of a hard drive are called bad sectors, and CHKDSK can detect them with a disk scan. CHKDSK will then attempt to fix the bad sectors so they’re usable again, potentially recovering the data in the process.

    A mockup of a hard drive, showing scattered red segments representing bad sectors and the order that results after running a CHKDSK scan in Windows.A disk with red segments representing bad sectors (above) and an organized disk (below).

    Here are the ways data gets corrupted:

    • Hard bad sectors occur when the media is physically damaged, like when a speck of dust lands on the disk or the read/write head makes contact and ruins the surface.

    • A soft bad sector is when malware or an improper shutdown confuses the disk drive. From that point on, the computer remembers that this data wasn't verifiable and marks it as a bad sector. You lose disk space and possibly even the file that didn't get written correctly.

    How to prevent corrupted data

    An increasing number of bad sectors means your hard drive is about to fail. Back up your data immediately to avoid losing it, and get a new hard drive. In the meantime, run CHKDSK regularly to keep your PC running as fast and smoothly as possible and tune up Windows 10 when you can.

    A large number of bad sectors can also indicate malware, which must be taken care of immediately if you don't want to lose any more data. Malware can cause your computer’s performance to suffer, with 100% disk usage at all times.

    When your hard drive is healthy, your PC boots up quickly and functions properly. Keep yours in top shape by running the defragger or letting your chosen malware and virus removal tool do a sweep to make sure there’s nothing hindering your computer’s performance.

    Don’t have time to mess with multiple apps to keep your computer in good shape? Want to use a tool that you can set and forget? AVG TuneUp automatically clears out all the stuff that builds up behind the scenes: browsing history, downloaded files, and more. Try it today with a free trial.

    CHKDSK Commands

    You can choose different CHKDSK parameters to pinpoint specific problems. The chkdsk command will search the disk drive for issues, but it won't fix any of them. If your results tell you that “No further action is required,” you won’t need to use these commands this time. 

    Here’s an overview of the CHKDSK commands:

    • chkdsk cross-references the directory of files with the file system to verify that they match.

    • chkdsk /f fixes any structural issues with the file system and directory, correcting inconsistencies between the two.

    • chkdsk /r searches for and fixes corrupted parts of the hard drive (while also running chkdsk /f). Sometimes it can’t fix the unusable or damaged sectors that it finds.

    • chkdsk /x dismounts a drive so that it can be checked and fixed. Running this command also runs /f.

    • chkdsk /v shows the path and name of all files while running a check.

    These commands will automatically run on the active drive shown next to your cursor. To run CHKDSK on a different drive, type chkdsk [drive letter]: /f, replacing [drive letter] with the letter of the drive you want to scan. For example, to repair the D drive, enter chkdsk D: /f.

    The drive with Windows on it (usually C) will ask you to restart before CHKDSK can run. Choose Y to continue.

    Image of command prompt with the appropriate command for running CHKDSK on the D drive. "chkdsk D: /f"

    What does chkdsk /r do?

    Chkdsk /r finds and attempts to repair corrupted portions of your hard drive. It automatically runs chkdsk /f as part of this process to correct logical errors on your disk as well. This means that you won’t have to run the command chkdsk /f /r.

    Before running chkdsk /r, check bad sectors for valuable files, as they may get deleted after the process completes. Chkdsk /r is not meant to be a data recovery program, and it sometimes doesn't recover corrupted files properly. The safest method for data recovery is to use a previously created backup, or to ask an expert before executing chkdsk /r

    If you're having trouble getting the scan to work, opening the command prompt as an administrator and running chkdsk /f /r /x should do the trick.

    CHKDSK Troubleshooting

    Here are some common issues that people struggle with before CHKDSK can run a disk scan.

    Volume is in use or read-only

    CHKDSK can’t run on any drives currently being used by Windows. Your drive needs to be inactive before CHKDSK can make any changes. Windows runs all sorts of services, including Service Host Superfetch, that keep a hard drive occupied.

    The following error messages indicate the drive is active and cannot be checked:

    • Cannot continue in read-only mode.

    • Volume is in use by another process.

    • Cannot lock current drive.

    All these errors mean that the drive is currently busy. You might have a photo open, for example, and you simply need to close the program so the volume is no longer in use.

    Check if you have a file open

    Use your Task Manager to see if there’s anything you can close.

    A screenshot of task manager, where there might be a program using a file on the external harddrive.

    Use Safe Mode

    Another possibility is that Windows is using your drive. You can get around this by agreeing to let CHKDSK run on the next startup. Type Y at this prompt:

    Command prompt showing the error message that the volume is in use by another process, and asking the user is they'd like to schedule this volume to be checked the next time the system restarts.

    If you’ve restarted but still can’t run CHKDSK, go to Advanced Options in Safe Mode. Repeatedly tap F8 at Startup to access these options. 

    You can also get to the advanced options from your desktop by following these steps:

    1. Go to Settings.

      A picture of a taskbar with Settings typed in, and the settings app has been circled.
    2. Open Update & Security Options.

      A screenshot of Windows 10's settings window. Update & Security is circled.
    3. Click Recovery.


      The menu for Update & Security in Windows Settings. "Recovery" is circled.
    4. Click Restart now under Advanced Startup.

      The "Recovery" options in Windows 10 settings. Under Advanced Startup, the "Restart now" button is circled.

    You will now go straight to the Advanced Startup options, where you can run the command prompt and execute a CHKDSK command on the Windows drive without issue. 

    One way to avoid these obstacles is to use an all-in-one maintenance program. AVG TuneUp knows the right time to scan your hard drive with CHKDSK, so you can safely forget about going into these advanced settings. It also covers everything from clearing the browser cache to deleting junk files.

    Enjoy a continually optimized PC without spending any time on it yourself. Try AVG TuneUp today.

    Older Windows versions

    Every outdated version of Windows can still run CHKDSK — even Windows XP. The blue screen of death has been with Windows since time immemorial, but so have disk scans and methods for dealing with the blue screen of death.

    Scanning and fixing hard drive issues with CHKDSK can help you avoid the blue screen of death.The dreaded blue screen of death.

    In any version of Windows, open the Command Prompt and the commands to use are the same. Use chkdsk /f for reviewing and fixing structural integrity, and chkdsk /r for finding and fixing bad sectors. 

    • In Windows XP, you can access the command prompt by clicking Start, then Run, and typing cmd.

    • In Windows Vista and Windows 7, type cmd in the Start menu search bar. You can run CHKDSK in Windows 7 or Vista just as you would in Windows 10. 

    • In Windows 8, you may need to press the Windows key + C to open the Charms bar, and then Search. Type cmd there. 

    Once you're in the Command Prompt, refer to the earlier instructions for running CHKDSK from the command prompt

    If you've started up an old computer and see a black screen, don't worry. You may be able to fix a black screen on Windows startup and make your computer usable again. 

    That computer might be riddled with issues like junk files or broken shortcuts. You might also want to physically clean the PC as well as use a dedicated PC cleaner tool — just don’t do both at the same time.

    Keep your PC performing at its best with AVG TuneUp

    It's always a welcome surprise when an ancient computer boots up normally. You can ensure that your current computer functions properly for years with proper PC maintenance. Even better, you don't have to do anything different — you just have to download one program that does it all for you. 

    AVG TuneUp schedules regular maintenance to clear out the stuff that commonly bogs down your PC. It uninstalls what you don't need, cleans up the files that aren't being used anymore, and automatically updates your programs. The result is a computer that runs faster than ever. Try AVG TuneUp for free right now.

    Optimize your Android with AVG Cleaner

    Free install

    Protect your iPhone against threats with AVG Mobile Security

    Free install