The magazine of the Melbourne PC User Group

Freeing disk space
George Skarbek
gskarbek@melbpc.org.au

If you use Windows then you may find many, often many hundreds of files ending in .TMP. All of these can be deleted. Also any files starting with ~ (tilde). Often most files ending in .BAK can also be deleted.

Deleting the TMP files is best done from DOS, with Windows closed as Windows can have several open TMP files making deleting harder. If you mark all TMP using File Manager and try to delete them, Windows will not let you. It will say "Access Denied." Make sure that disk is not full or write protected.

Type DIR C:\*.TMP /S /P, and note in what subdirectories these files exist, then change to the subdirectory and type DEL *.TMP or DEL ~*.*. or use XTree file spec *.tmp *.bak ~*.*, Show All.

Then run SCANDISK. If it reports lost allocation units, just delete them as in almost all cases this is just rubbish left behind. Occasionally a lot of space can be freed.

If you have files in the root directory (type CD\ to move there) called FILE000x.CHK, then delete all of them. They are not required.

The best result obtained was to delete 85 MB of junk from a 120 MB hard disk!

DOS

If you do not use foreign languages in DOS then delete the following files from the DOS sub-directory; *.CPI, KEYB*.*, NLSFUNC.EXE and DISPLAY.SYS.

If you have Windows and have not used the MS-DOS shell program then delete DOSSHELL.*, *.VID.

If you do not plan to link two computers via serial or parallel ports then delete INTER*.EXE. Delete POWER.EXE if your computer is not a laptop.

Do not delete hidden files unless you are absolutely sure of what they do and that they are dispensable.

Windows

Another area where space may be reclaimed is the Windows swap file. This large hidden file called 386SPAR.PAR. Windows can use virtual memory to help with memory demands. Virtual memory is the hard disk space that is treated as RAM and takes the form of a swap file. The size of that file determines how much of your disk you wish to set aside for virtual memory. When Windows is low in physical memory it will write part of the current memory to the hard disk. This swapping of physical memory to disk makes more resources available to Windows (but disk access is vastly much slower than memory access).

Disk space can be conserved for DOS applications by using a temporary swap file, which is deleted after exiting Windows. The penalty is slightly slower response, and if the disk fills, or becomes very fragmented, Windows will not be able to use any swap file.

The formula used by Windows in determining the size of the swap file is excessive for most cases. I have 8 MB of RAM and I have set my swap file size to 6 MB. I rarely run more than four simultaneous applications and I almost never run out of memory. My recommendation is if you run Windows regularly, use the permanent swap file, but if you use mainly DOS with the occasional Windows program, a temporary swap file will give you more hard disk space.

To view or alter the size of your swap file, from the Control Panel select 386 and then Virtual Memory and adjust accordingly.

To remove Windows-related files

Run Setup, from Main, then from Options, select Add/Remove (see Figure 1.)

Click on Select Files and you will get a choice, similar to the one in Figure 2.


Figure 1


Figure 2

Remove the ones that you have never used and are not likely to use. They can always be reinstalled from the original disks without affecting the existing setup. Typical candidates are; All README files, CARDFILE and the HELP file. MEDIA PLAYER if you don't have a sound card. TERMINAL if you don't have a modem and not likely to get one, or have something better (almost anything is better). OBJECT PACKER, RECORDER. Also look at wallpapers.

Another area is Fonts, from Control Panel. Many programs add fonts. These take up disk space and slow Windows loading. Care is required not to delete the ones Windows uses. These are found in the Win.ini file:

[FontSubstitutes]
Helv=MS Sans Serif
Tms Rmn=MS Serif
Times=Times New Roman
Helvetica=Arial


WP adds Hebrew, Arabic, Japanese and many others. When deleting them, tick the box "Delete from disk."

Finally after all the deletions, exit Windows and type DEFRAG (DOS 6.0 and higher) to improve disk performance.

Running CHKDSK or SCANDISK and deleting any *.TMP files and defragmenting should be done at regular intervals.

Reprinted from the February 1996 issue of PC Update, the magazine of Melbourne PC User Group, Australia

[About Melbourne PC User Group]