Hack113.Hack Your Way to a Cleaner Hard Disk


Hack 113. Hack Your Way to a Cleaner Hard Disk

Cut through the clutter, clean up your hard disk, and reclaim space you never knew you had with these hacks, techniques, and downloads.

No matter how much hard-disk space you have, it's just never enough. Your hard disk is littered with old files you no longer need, temporary files, cache files, and more clutter than an old attic. Here's how to hack your way to a cleaner hard disk.

12.7.1. Create Separate Hard-Disk Cleanup Profiles

XP's Disk Cleanup tool (Control Panel Performance and Maintenance "Free up space on your hard disk") is a quick-and-dirty way to clean your hard disk of unnecessary files. It calculates how much hard-disk space you can save by deleting a variety of different file types and caches or compressing and archiving old files you rarely use (see Figure 12-8).

Figure 12-8. The Disk Cleanup tool reporting how much hard-disk space it can free up


But enabling and disabling all its various options each time can be time-consuming. And simply using the settings from the last run might not quite suit your fancy. Sometimes you might want only certain files deleted and others kept around a little longer. For example, your temporary Internet files speed up your browsing experience by keeping on hand the graphics files associated with sites you frequently or have recently visited.

To solve this problem, you can create separate disk-cleanup profiles; that way, whenever you want your hard disk cleaned in a certain way, you can run just that one profile. For another set of cleanup options, just use a different profile.

While these profiles aren't available via the GUI, you can get at them under the covers by using the command-line version of the Disk Cleanup tool: cleanmgr.exe. First, you need to create a new disk-cleanup profile. Type cleanmgr /Saveset:n, where n is any number between 1 and 65535. The Disk Cleanup Settings dialog will appear, as shown in Figure 12-9, allowing you to select which items you would like to be cleaned using this profile.

Figure 12-9. The Disk Cleanup Settings screen


While at first blush it might appear you've reached the same dialog you reached using the GUI version of Disk Cleanup, take a closer look. You'll notice you're offered more cleanup options. You're able to automatically remove debug dump files, setup log files, catalog files for the Content Indexer, temporary setup files, old Chkdsk files, and various other items the GUI version doesn't offer to clean for you.

If you're creating a profile to clean a drive other than the one containing Windows, most of these options won't be enabled. You'll be able to automatically clean only the Recycle Bin and catalog files for the Content Indexer.


Make your selections and click OK to create your cleanup profile. To run this profile at any time, type cleanmgr /Saverun:n, where n is the number of the profile you've just created.

When using Disk Cleanup, from either the command line or the Windows GUI, be careful when letting it delete downloaded program files. These are often ActiveX programs and Java add-ins that are frequently useful, so let it delete them only if you know you don't use them.


12.7.2. Clean Your Hard Disk Without Disk Cleanup

Frequently, cleaning your hard disk manually is more effective than using Disk Cleanup. Disk Cleanup won't find all the files you want to delete, and it might also delete files you'd prefer to keep. For example, Disk Cleanup won't delete all the files in your \TEMP directory, even though it says it will. Also, it doesn't touch files that are less than one week old.

A manual cleaning should include the following steps:

  1. Empty the Recycle Bin.

  2. Search for all files that end in .bak and .tmp and that start with ~ (use the wildcard * when you searchfor example, *.tmp, *.bak, and ~*.*). Delete them all, except for any files that are dated the current or previous day. You might find some files can't be deleted because they are in use. Don't worry about it; just leave them.

  3. Delete your temporary Internet files by running Internet Explorer and choosing Tools Internet Options General Delete Files.

  4. Delete old system restore points, which can take up a substantial amount of space. You can delete all your old system restore points except the most current one, so before doing this, make sure you don't need any old points. Run Disk Cleanup, then choose the More Options tab and click the Clean Up button in the System Restore section.

12.7.3. Download a Better Disk-Cleanup Tool

Disk Cleanup works fine for a free built-in tool. But you can download tools that can do an even better job; such tools can find and delete duplicate files, delete orphan shortcuts that link to programs that no longer exist, and similar functions. There are many out there; two of the best are CleanUp! and System Mechanic.

CleanUp! (http://www.emesoft.se; $18, trial version available) expands on XP's Disk Cleanup tool by finding and deleting shortcuts and favorites that are no longer valid, giving you a list of Registry entries that point to files no longer on your hard disk, and letting you examine and delete Internet Explorer AutoComplete entries.

System Mechanic (http:/www.iolo.com; $59.95, trial version available) is far more than a disk-cleanup tool. In addition to normal cleanup tasks, it finds and deletes obsolete and junk files that are left behind by uninstalled programs, finds and deletes duplicate files, finds and fixes broken shortcuts, cleans out the Registry, lets you fine-tune Windows settings, provides privacy protection, and more. In all, it offers a suite of 15 utilities.



    Windows XP Hacks
    Windows XP Hacks, Second Edition
    ISBN: 0596009186
    EAN: 2147483647
    Year: 2003
    Pages: 191

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net