


How to use the fsutil command for file system management in Windows
Jul 30, 2025 am 01:53 AMUse fsutil fsinfo ntfsinfo C: to check NTFS volume details like serial number and cluster size. 2. Get file details by ID with fsutil file queryfilenamebyid or queryfileid, requiring admin rights. 3. Create hard links via fsutil hardlink create C:\link.txt C:\original.txt to share file data. 4. Check disk space with fsutil volume diskfree C: for total, free, and available space. 5. Disable 8.3 filenames using fsutil behavior set disable8dot3 C: 1 for performance. 6. Manage sparse files with fsutil sparse setflag and setrange to save disk space. 7. Query reparse points via fsutil reparsepoint query C:\junction to inspect symlinks or junctions. Always run fsutil as Administrator, verify paths, and use cautiously for diagnostics or scripting to avoid data issues, making it a powerful tool for administrators troubleshooting file system behavior.
The fsutil
command in Windows is a powerful built-in tool that lets you manage and troubleshoot file systems, particularly NTFS. It allows you to perform low-level operations like checking file details, managing disk space, manipulating hard links, and more—all from the Command Prompt. Here’s how to use it effectively for common file system tasks.

1. Check File System Type and Volume Information
Before making changes, it's helpful to know what kind of file system you're working with.
fsutil fsinfo ntfsinfo C:
This command displays detailed information about the NTFS volume on drive C:, including:

- Volume serial number
- Number of sectors
- Bytes per cluster
- Total free and used space
You can also list all drives on the system:
fsutil fsinfo drives
And get general file system info (FAT32, NTFS, etc.) for a specific drive:

fsutil fsinfo drivetype C:
2. Manage File and Directory Operations
Get File Details (Including MFT Record)
To view low-level details about a specific file, such as its file reference number and creation time:
fsutil file queryfilenamebyid C:\path\to\file.txt
?? Note: You may need to enable debug privileges first using
fsutil behavior set disable8dot3 0
or run as Administrator.
You can also query a file by its ID in the Master File Table (MFT):
fsutil file queryfileid C: 12345
Replace 12345
with the actual file ID.
Create Hard Links
Hard links let multiple directory entries point to the same file data on disk. Use fsutil
to create one:
fsutil hardlink create C:\link\newlink.txt C:\original\file.txt
Now both paths refer to the same data. Deleting one doesn’t affect the other until the last link is removed.
3. Disk Space Management
Use fsutil
to check how space is allocated on a drive.
View Free Space on a Drive
fsutil volume diskfree C:
This returns:
- Total disk space
- Free space
- Available space (accounting for quotas or reserved areas)
This is useful for scripting or diagnosing apparent "missing" space.
Disable or Enable 8.3 Filename Creation (Short Names)
By default, Windows creates short (8.3 format) names for files like LONGFI~1.TXT
. You can disable this for performance on SSDs or servers:
fsutil behavior set disable8dot3 C: 1
To re-enable:
fsutil behavior set disable8dot3 C: 0
Check current status:
fsutil behavior query disable8dot3
4. Troubleshoot Sparse Files and Reparse Points
Work with Sparse Files
Sparse files are files that appear large but consume little actual disk space because empty regions aren’t stored.
To set a file as sparse:
fsutil sparse setflag C:\sparsefile.txt
Then set a range of the file as "empty":
fsutil sparse setrange C:\sparsefile.txt 0 1048576
This creates a 1MB sparse region starting at byte 0.
Query Reparse Points (Used by Symlinks, Junctions, etc.)
To see if a file or directory has a reparse point (used in symbolic links or mount points):
fsutil reparsepoint query C:\myjunction
This returns the reparse tag and data, which helps identify what type of link or redirect is in place.
Tips for Using fsutil Safely
- Always run Command Prompt as Administrator—many
fsutil
commands require elevated privileges. - Be cautious with low-level operations—they can affect system stability or data integrity.
- Double-check file paths and IDs before running destructive or irreversible commands.
- Use
fsutil
primarily for diagnostics and automation; GUI tools are safer for routine tasks.
Common fsutil Commands at a Glance
Task | Command |
---|---|
List all drives | fsutil fsinfo drives |
Get NTFS info | fsutil fsinfo ntfsinfo C: |
Check free space | fsutil volume diskfree C: |
Create hard link | fsutil hardlink create <new> <existing></existing></new> |
Set file as sparse | fsutil sparse setflag <file></file> |
Query reparse point | fsutil reparsepoint query <path></path> |
Disable 8.3 names | fsutil behavior set disable8dot3 1 |
Using fsutil
gives you granular control over Windows file systems, especially useful for scripting, performance tuning, or troubleshooting disk issues. While not needed for everyday use, it’s a valuable tool for admins and power users.
Basically, if you're digging into how files are stored or why space isn’t adding up, fsutil
is one of the best places to start.
The above is the detailed content of How to use the fsutil command for file system management in Windows. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undress AI Tool
Undress images for free

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

The problem of slow booting can be solved by the following methods: 1. Check and disable unnecessary booting programs; 2. Turn off the quick boot function; 3. Update the driver and check disk health; 4. Adjust the number of processor cores (only for advanced users). For Windows 11 systems, first, the default self-start software such as QQ and WeChat are disabled through the task manager to improve the startup speed; if you use dual systems or old hardware, you can enter the power option to turn off the quick boot function; second, use the device manager to update the driver and run the chkdsk command to fix disk errors, and it is recommended to replace the mechanical hard disk with SSD; for multi-core CPU users, the kernel parameters can be adjusted through bcdedit and msconfig to optimize the startup efficiency. Most cases can be corrected by basic investigation

If you're having trouble reading your desktop icons' text or simply want to personalize your desktop look, you may be looking for a way to change the font color on desktop icons in Windows 11. Unfortunately, Windows 11 doesn't offer an easy built-in

Fixed Windows 11 Google Chrome not opening Google Chrome is the most popular browser right now, but even it sometimes requires help to open on Windows. Then follow the on-screen instructions to complete the process. After completing the above steps, launch Google Chrome again to see if it works properly now. 5. Delete Chrome User Profile If you are still having problems, it may be time to delete Chrome User Profile. This will delete all your personal information, so be sure to back up all relevant data. Typically, you delete the Chrome user profile through the browser itself. But given that you can't open it, here's another way: Turn on Windo

When Windows cannot detect a second monitor, first check whether the physical connection is normal, including power supply, cable plug-in and interface compatibility, and try to replace the cable or adapter; secondly, update or reinstall the graphics card driver through the Device Manager, and roll back the driver version if necessary; then manually click "Detection" in the display settings to identify the monitor to confirm whether it is correctly identified by the system; finally check whether the monitor input source is switched to the corresponding interface, and confirm whether the graphics card output port connected to the cable is correct. Following the above steps to check in turn, most dual-screen recognition problems can usually be solved.

Mini PCs have undergone

Have problems uploading files in Google Chrome? This may be annoying, right? Whether you are attaching documents to emails, sharing images on social media, or submitting important files for work or school, a smooth file upload process is crucial. So, it can be frustrating if your file uploads continue to fail in Chrome on Windows PC. If you're not ready to give up your favorite browser, here are some tips for fixes that can't upload files on Windows Google Chrome 1. Start with Universal Repair Before we learn about any advanced troubleshooting tips, it's best to try some of the basic solutions mentioned below. Troubleshooting Internet connection issues: Internet connection

When encountering the problem of printing task stuck, clearing the print queue and restarting the PrintSpooler service is an effective solution. First, open the "Device and Printer" interface to find the corresponding printer, right-click the task and select "Cancel" to clear a single task, or click "Cancel all documents" to clear the queue at one time; if the queue is inaccessible, press Win R to enter services.msc to open the service list, find "PrintSpooler" and stop it before starting the service. If necessary, you can manually delete the residual files under the C:\Windows\System32\spool\PRINTERS path to completely solve the problem.
