Windows XP Defragmenter
If the results of the analysis suggest that the disk should be defragmented you can do this as follows:
- If the Disk Defragmenter tool is not already running, click Start, point to All Programs > Accessories > System Tools, then click Disk Defragmenter.
- Select the disk that you want to defragment, then click Defragment to begin.
- Review the progress of the operation in the Defragmentation Display window.
Fragmented files on the disk appear in red, contiguous files are blue, and system files are green. We want to eliminate most of the red in the window.
The Windows XP Disk Defragmenter can also be run from the Disk Defragmenter Console, which can be opened by going to the Start menu and typing dfrg.msc at the run line, then clicking OK. The defrag command used in older versions of windows will not work in the XP run line, but id does work if you use the command prompt.
Even after running the defragmenter, some files can remain fragmented, eg: files that are in use are left alone by the defragmenter so things like pagefile.sys will not be defragmented. You can download a free PageDefrag utility that will defragment paging files, Registry hives, event log files and hibernation files from http://www.sysinternals.com/Utilities/PageDefrag.html
It is a good idea to clear any temporary files (including the internet cache) and close down any unnecessary programs running in the background before defragmenting a disk.