Defrag a drive in Windows 7 using command line [How-to]
Although windows comes with a powerful defragmentation utility, there might be instances when you would want to defrag your drive using the command line. Even when you don’t have a reason to use the command line for defragmenting your drive, you might wanna do it because it’s cool and you can show off your power user status in front of your friends.
Let’s see how to defrag a drive using command line in Windows 7.
1. To view the fragmentation analysis of your drive (say C:),
type the following at the command prompt:
defrag c: -a -v
-a tells the defragger to perform a fragmentation analysis on the drive in question (C: in this case). -v tells it to be verbose in its report. You can change the drive letter to check the fragmentation analysis for that drive.
2. To defrag a drive (in this case c:)
defrag c: -v -r
-r says the defrag utility to treat files that are fragmented with 64 MB fragments or larger as though they are not fragmented. This is default in Windows 7.
3. To defrag every file irrespective of it’s size
defrag c: -v -w
-w tell the defrag utility to defrag everything.
This option is not available in the GUI defragmenter utility on Windows 7 and hence command line gives you better option to defrag your drive.
- Defraggler: An ideal free substitute to Windows disk defragmenter
- Access your Vista partition in Windows 7 [Windows 7 How-to]
- Use command prompt in Vista with elevated admin rights
- How to change the filetype association for a file in Windows
- Free up disk space post Windows 7 install: Disk Cleaning in Windows 7
- Use your FTP as a local drive in Windows using NetDrive
- Install non compatible applications in Windows 7: Install Dreamweaver in compatibility mode in Windows 7
- How to SVN in Windows
- Already bored of Windows 7 themes: Get new Windows 7 themes
- Burn ISO image in Windows 7 without third party software