Why defrag?
Windows 98, Windows Me and Windows XP come with a collection of house cleaning tools, including ScanDisk, Disk Defragmenter and Disk Cleanup, to help keep your disk in peak working order.
Why should you bother with the housework? A couple of reasons. First, disks are hard working, mechanical devices and, like all mechanical devices, prone to failure. A little preventative maintenance can warn you of potential problems and fix minor glitches before they can do damage to your data.
Second, the way files are organised on your drive has a perceptible impact on the performance of your computer. If your files are stored neatly, end-to-end, without fragmentation, reading and writing to the disk is speedier.
What is file fragmentation?
Sometimes when you install a program or create a data file, the file ends up chopped up into chunks and stored in multiple locations on the disk. This is called fragmentation.
What makes this happen?
When you first install your operating system and programs on your hard disk, they are written to the disk, for the most part, in one contiguous block without any gaps. The exceptions are certain system files that must be stored in specific locations. Over time, as you create and then delete documents or uninstall programs, once-filled locations are left empty and you end up with files dotted all over the disk.
Now, when Windows is writing a file to the disk, it looks for a suitable piece of free space in which to store it. What happens, then, when you copy a 40MB database or a 100MB video clip to the disk and the biggest slice of free space is only 30MB? Or say you modify an existing file, appending a whole bunch of data so the file now takes up more space on the disk. To accommodate the files, Windows writes the first part of the file in one section of the disk and then scouts around for other places to store the rest of the file. The end result is that a single file may be stored in several chunks scattered about the disk.
Of FAT and files
Your operating system needs to have a way of keeping track of each file’s location. Windows 98 and Windows Me use a system called FAT32. The ‘FAT’ stands for File Allocation Table. When your file is written to disk, FAT32 provides Windows with the address of an unoccupied disk cluster. FAT32 also tells Windows on which disk sectors it will find that cluster; that is, it provides the physical location of the cluster. This information is used by your PC’s BIOS (the Basic Input/Output System) to direct the actual disk writing operation.
If the file is too large to fit in a single cluster, Windows asks FAT32 for another vacant cluster, and another, and another until the whole file is written to disk. If you have lots of free clusters side by side, FAT32 can point Windows to an adjacent series of clusters, resulting in a file which occupies one contiguous chunk of the disk. If no adjacent cluster is available, FAT32 tracks down a space elsewhere on the disk and tells Windows to put the next bit of the file there; and so on until the full file is written to disk.
A record of the clusters used for storing the file is kept by FAT32 so Windows can find the file once more when you want to read it.
Windows XP does NTFS
FAT was introduced in the pre-Windows days when we used an operating system called DOS (Disk Operating System). When Windows 95 appeared on the scene, it originally used FAT, but with Service Pack 2 it shifted to FAT32. More recent versions of Windows don’t use FAT at all; they use NTFS, a file system developed for the server operating system, Windows NT.
When it comes to file systems, Windows XP is a fence sitter. If you install it from scratch it will, by default, use NTFS. But if you upgrade an old computer running Windows 98 or Me to Windows XP, XP inherits the old FAT32 file system, giving you an option to convert to NTFS. NTFS is more reliable and more efficient than FAT32, so in most cases it makes sense to use it.
The fragmentation penalty
Although this all happens quickly, it makes a lot of work for your hard disk. Its read/write head, which moves across the drive platter from location to location transferring data, has to zip all over the place when saving or opening a single highly fragmented file. (By the way, many disks have more than one read/write head and multiple platters.) If a file is unfragmented, the disk head moves to one location, reads the file in one sequential swoop, and that’s it.
A file stored in, say, four fragments, can easily take twice as long to open as the same file unfragmented, although the actual performance hit you take is affected by other factors, including the total size of the file.
Defragging
There’s a simple solution to file fragmentation: use Windows Disk Defragmenter. To do so, click:
Start -> (All) Programs -> Accessories -> System Tools -> Disk Defragmenter
This utility, commonly called Defrag, gathers all the scattered file fragments and writes them into adjacent clusters, so each file occupies an unbroken section of the disk.
NTFS, XP and defragging
From a defragging perspective, it doesn’t matter whether your operating system is FAT32 or NTFS, you still need to defragment. Windows XP’s Disk Defragmenter looks a little different from the one you’ll find in Windows 98 and Windows Me, but it works in a similar way. XP’s Defragmenter is somewhat smarter than its predecessors and isn’t as easily thrown off its stride by background programs.
Defrag works by moving slabs of data to unused parts of the disk, in order to open up a large free section of space. It then assembles the fragmented parts of a file and writes them in one complete piece to the cleared space; it then does the same with the next file; and so on until the entire disk is defragmented.
Powerful alternatives
The built-in Disk Defragmenter is a utility which has been hobbled by the rapid advance of drive technology. It works just fine on a disk of 8G or so; but use it on a 20G drive or – if you dare – an even larger drive and you can say goodbye to using your computer for the most part of a day. Although Microsoft says it’s okay for you to use your computer while defragging, in practice this rarely works, because every write to disk causes Defrag to restart.
If you’d like to speed up Defrag and eliminate some of its problems, try one of the commercial defraggers. They’re far more at home with large hard drives, run on all versions of Windows from XP onwards, and they provide a less frustrating experience. Some of the alternatives are:
Defrag goes auto in Vista and Windows 7
With Vista and Windows 7, defragging happens automatically in the background whenever your computer is idle. If the defrag process is interrupted, it will resume the next time your computer is sitting idle. So for most Vista and Win 7 users, defragging becomes a non-issue.
Step-by-step: Efficient defragging
- Defrag works most efficiently when your drive has ample space for its operations. If you run Defrag with a drive that’s chockablock, it must work like mad simply to clear enough space to start writing files. So it pays to delete all unnecessary files before you start defragging. Uninstall unwanted programs, archive old data, delete unwanted backups, and then run Disk Cleanup (Start -> (All) Programs -> Accessories -> System Tools -> Disk Cleanup).
- Defrag also works best when completely uninterrupted. Background programs such as Task Scheduler and anti-virus software can cause Defrag to stop and restart repeatedly. To avoid such interruptions, do a clean boot before running Defrag:
a. Click Start -> Run, type msconfig in the Open box and click OK to open the System Configuration Utility.
b. On the General tab, click Selective Startup and remove the ticks beside Process System.ini File, Process Win.ini File and Load Startup Group Items. (On some versions of Windows you may also see Config.sys, Autoexec.bat and Winstart.bat options -Â remove the ticks beside these as well).
c. Click OK and allow your computer to restart.
- Once you’ve cleaned out unnecessary files and stopped background programs from loading, you’re ready to defrag:
a. Click Start -> Programs -> Accessories -> System Tools -> Disk Defragmenter.
b. Select the drive you wish to defrag.
c. Click Settings and make sure there’s a tick beside the two options in the section When Defragmenting My Hard Drive, then click OK twice to begin.
d. After Defrag has finished, open the System Configuration Utility once more, click Normal Startup on the General tab, click OK and reboot.
Related posts:
- Installing Windows 7 onto a disc-less computer
- Recovering deleted files
Incoming search terms for the article:
Similar articles
- 23 Ways To Speed WinXP Without Defrag
To defrag, or not to defrag? If you’re looking for ways to speed WinXP machines used by your customers, then the answer is Not. Defragmenting, of course, is the process of reorganizing all data on a hard-disk drive so that each file is arranged into a single uninterrupted, or contiguous, location on the disk.
... - A Simple way to Speed up Your PC, and It’s Free
Not many individuals are aware that among the many fundamental ways in which to speed up a computer, shall be to simply defrag itÂ’s hard drive. Some operating systems donÂ’t require the systems hard rive to be defragged, since it hinges on which file system is being used, but the most used file systems are
... - Slow Computer Solutions, Defrag That Hard Drive For a Faster PC
Slow Computer Solutions, Defrag That Hard Drive For a Faster PC Jun 27, 2010 David Wigle One of the big selling points of computer optimization software when considering their ‘bring back that speedy new computer feel’ type comments, is the defragment feature. Defragmenting a hard drive reorganizes everything so that it is easier for the
... - 4 Tricks to Speed Up Your Computer
Do you know the difference between an old computer and one that just needs to be tweaked? Find out how to speed up your computer, so you don’t have to buy a new one. These four tricks will get your computer running like new again. #1 Defrag Windows XP, Vista and Windows 7 all come
... - My computer become slow
Couple of things are inevitable with PCs that slows them down: – Registry becomes fragmented or full of past-installation leftovers – HD becomes fragmented Registry can be cleaned and defragmented using tool called “Free Registry Defrag” (among other free registry tools). It defragments and compacts the registry files. For the HD,
...
One consequence of this is that for large files it may be faster to
let each process run sequentially, so the hard disk controller can
concentrate on getting all the data from one part of the platter
before moving the heads to another region to get the next file.
Otherwise the hard disk ends up spending most of its time seeking
(also known as “thrashing” because of the loud noise the old drives
used to make when the heads moved frantically).
Fragmented files, especially large ones broken into lots of small
fragments, are slower to retrieve from a disk than sequential files
due to the amount of time the disk spends just “spinning” without
doing any useful work, whilst the heads are seeking to the start of
the next fragment.
Most processes block when they are waiting to read file data. Each
request for a file gets put in a queue (the hard disk controller’s
queue). There is only one hard disk controller, so if ten processes
all ask for a different file at the same time, all ten processes
will block and the hard disk controller then has to go away and
seek out each file (or part thereof) as quickly as it can.
Is that D: drive possibly a backup partition created by the
computer maker? If you don’t know what’s on it and it’s only 5.68GB
in size, it’s quite likely that it’s simply there to hold a backup
copy of your original system installation. In that case, you really
should just leave it alone; you certainly don’t want to go deleting
files from it to make room to defrag if you don’t know what those
files are.