ChkDsk Syntax
The command-line syntax for ChkDsk is
Chkdsk [volume[[path] filename]] [/f] [/v] [/r] [/x] [/i] [/c] [/b] [/l[:size]]
Table-4 lists all ChkDsk command-line parameters. Unless otherwise noted, parameters apply to any file system type.
Table-4 ChkDsk Parameters
Parameter | Description |
volume | Specifies the volume that you want ChkDsk to check. You can specify the
volume by using any of the formats in the following examples: To run ChkDsk on the C volume, specify c: To run ChkDsk on a mounted volume called data that is mounted on the C volume, specify c:\data To run ChkDsk on a volume, you can specify the symbolic link name for a volume, such as \\?\Volume{109d05a2-6914-11d7-a037-806e6f6e6963}\ You can determine a symbolic link name for a volume by using the mountvol command. |
path | FAT/FAT32 only. Specifies the location of a file or set of files within the folder structure of the volume. |
filename | FAT/FAT32 only. Specifies the file or set of files to check for <a ID="wPopUp" HREF="HELP=glossary.hlp TOPIC=gls_fragmentation"> fragmentation </a>. Wildcard characters (* and ?) are allowed. |
/f | Fixes errors on the disk. The volume must be locked. If ChkDsk cannot lock the volume, ChkDsk offers to check it the next time the computer restarts. |
/v | On FAT/FAT32: Displays the full path and name of every file on the disk. On NTFS: Displays additional information or cleanup messages, if any. |
/r | Locates <a ID="wPopUp" HREF="HELP=glossary.hlp TOPIC=glos_glo_cigj"> bad sectors </a> and recovers readable information (implies /f ). If ChkDsk
cannot lock the volume, it offers to check it the next time the computer starts. Because NTFS also identifies and remaps bad sectors during the course of normal operations, it is usually not necessary to use the /r parameter unless you suspect that a disk has bad sectors. |
/x | Forces the volume to dismount first, if necessary. All opened handles to the volume are then invalid (implies /f ). This parameter does not work on the boot volume. You must restart the computer to dismount the boot volume. |
/i | NTFS only. Performs a less-detailed check of index entries, reducing the amount of time needed to run ChkDsk. |
/c | NTFS only. Skips the checking of cycles within the folder structure, reducing the amount of time needed to run ChkDsk. |
/i:size | NTFS only. Changes the size of the log file to the specified number of kilobytes. Displays the current size if you do not enter a new size. If the system loses power, stops responding, or is restarted unexpectedly, NTFS runs a recovery procedure when Windows restarts. This procedure accesses information stored in this log file. The size of the log file depends on the size of the volume. In most conditions, you do not need to change the size of the log file. However, if the number of changes to the volume is so great that NTFS fills the log before all metadata is written to disk, then NTFS must force the metadata to disk and free the log space. When this condition occurs, you might notice that Windows stops responding for 5 seconds or longer. You can eliminate the performance impact of forcing the metadata to disk by increasing the size of the log file. |
/b | NTFS only. Re-evaluates bad clusters on the volume. This is typically not necessary, but it might allow you to reclaim some lost disk space on a hard disk with a large number of bad clusters. However, these clusters might experience problems in the future, decreasing reliability. |
/? | Displays information about using ChkDsk. |
In this tutorial:
- Troubleshooting Hardware, Driver, and Disk Issues
- Windows 7 Improvements for Hardware and Driver Troubleshooting
- Windows Troubleshooting Platform
- Built-in Troubleshooting Packs
- Windows Troubleshooting Platform Components
- Creating Custom Troubleshooting Packs
- Running Troubleshooting Packs Remotely
- Windows 7 Reliability Monitor
- Windows 7 Resource Monitor
- Windows Memory Diagnostics
- Disk Failure Diagnostics
- Self-Healing NTFS
- Improved Driver Reliability
- Improved Error Reporting
- The Process of Troubleshooting Hardware Issues
- How to Troubleshoot Problems That Prevent Windows from Starting
- How to Troubleshoot Problems Installing New Hardware
- How to Troubleshoot Problems with Existing Hardware
- How to Troubleshoot Unpredictable Symptoms
- How to Diagnose Hardware Problems
- How to Use Device Manager to Identify Failed Devices
- How to Check the Physical Setup of Your Computer
- How to Check the Configuration of Your Hardware
- How to Verify That System Firmware and Peripheral Firmware Are Up to Date
- How to Test Your Hardware by Running Diagnostic Tools
- How to Simplify Your Hardware Configuration
- How to Diagnose Disk-Related Problems
- How to Use Built-In Diagnostics
- How to Use Reliability Monitor
- How to Use Event Viewer
- How to Use Data Collector Sets
- How to Use Windows Memory Diagnostics
- Memory Failures
- How Windows Automatically Detects Memory Problems
- How to Schedule Windows Memory Diagnostics
- How to Start Windows Memory Diagnostics When Windows Is Installed
- How to Start Windows Memory Diagnostics from the Windows DVD
- How to Configure Windows Memory Diagnostics
- How to Troubleshoot Disk Problems
- How to Prepare for Disk Failures
- How to Use ChkDsk
- ChkDsk Examples
- ChkDsk Syntax
- How to Use the Graphical ChkDsk Interface
- How to Determine Whether ChkDsk Is Scheduled to Run
- ChkDsk Process on NTFS Volumes
- How to Use the Disk Cleanup Wizard
- How to Disable Nonvolatile Caching
- How to Troubleshoot Driver Problems
- How to Find Updated Drivers
- How to Roll Back Drivers in Windows 7
- How to Use Driver Verifier
- How to Use the File Signature Verification
- How to Use Device Manager to View and Change Resource Usage
- How to Use Windows 7 System Restore
- How to Troubleshoot USB Problems
- How to Solve USB Driver and Hardware Problems
- Understanding USB Limitations
- How to Identify USB Problems Using Performance Monitor
- How to Examine USB Hubs
- How to Troubleshoot Bluetooth Problems
- Troubleshooting Tools
- DiskView
- Handle
- Process Monitor