Galactic Concepts

Custom Search
Home
System Performance


Automate Disk Defragmentation

In Windows XP you can automate disk defragmentation by doing the following.

For example to defrag your C drive:
Create a .bat file and paste the following lines inside:

 defrag.exe -v c:  >c:\defragLogFile.txt   

The c: switch targets the c: drive for the defrag.
The -v switch enables verbose logging.
The >c:\defragLogFile.txt writes the output to the file called defragLogFile.txt.

Create a scheduled task that runs weekly at a specific time. (In the middle of the night!)