Index | Example | Syntax  



DEFRAG--Notes

Network and INTERLNK drives You cannot use DEFRAG to optimize network drives or drives created with   INTERLNK. Disk information reported by DEFRAG and CHKDSK Disk information that DEFRAG reports differs from information that CHKDSK reports. DEFRAG reports hidden and user files as one number; CHKDSK reports numbers for each type. DEFRAG counts the root as a directory; CHKDSK does not. DEFRAG does not count the volume label as a file; CHKDSK does. Start DEFRAG only from MS-DOS If you start DEFRAG from a program such as Microsoft Windows, you may lose data. DEFRAG exit codes The following list briefly describes the meaning of each DEFRAG exit code (ERRORLEVEL parameter): 0 The defragmentation was successful. 1 An internal error occurred. 2 The disk contained no free clusters. To operate, DEFRAG needs 1 free cluster. 3 The user pressed CTRL+C to stop the process. 4 A general error occurred. 5 DEFRAG encountered an error while reading a cluster. 6 DEFRAG encountered an error while writing a cluster. 7 An allocation error occurred. To correct the error, use the <SCANDISK> command. 8 A memory error occurred. 9 There was insufficient memory to defragment the disk. You can use the ERRORLEVEL parameter on the IF command line in a batch program to process exit codes returned by DEFRAG. For an example of a batch program that processes exit codes, see the <CHOICE> command.
-Top- | Example | Syntax Section 5.6