DISKCOPY--Notes
Invalid drive for DISKCOPY
DISKCOPY messages
Disk serial numbers
Omitting drive parameters
Using one drive for copying
Avoiding disk fragmentation
Copying Startup disks
DISKCOPY exit codes
Invalid drive for DISKCOPY
The DISKCOPY command works only with uncompressed removable disks, such as
floppy disks. You cannot use DISKCOPY with a hard disk or a network drive.
If you specify a hard disk drive for drive1 or drive2, DISKCOPY displays the
following error message:
Invalid drive specification
Specified drive does not exist
or is non-removable
DISKCOPY messages
The DISKCOPY command prompts you to insert the source and destination disks
and waits for you to press any key before continuing.
After copying, DISKCOPY displays the following message:
Copy another diskette (Y/N)?
If you press Y, DISKCOPY prompts you to insert source and destination disks
for the next copy operation. To stop the DISKCOPY process, press N.
If you are copying to an unformatted floppy disk in drive2, DISKCOPY formats
the disk with the same number of sides and sectors per track as are on the
disk in drive1. DISKCOPY displays the following message while it formats the
disk and copies the files:
Formatting while copying
If the capacity of the source disk is greater than that of the destination
disk and your computer can detect this difference, DISKCOPY displays the
following message:
Drive types or diskette types not compatible
Disk serial numbers
If the source disk has a volume serial number, DISKCOPY creates a new volume
serial number for the destination disk and displays the number when the copy
operation is complete.
Omitting drive parameters
If you omit the drive2 parameter, DISKCOPY uses the current drive as the
destination drive. If you omit both drive parameters, DISKCOPY uses the
current drive for both. If the current drive is the same as drive1, DISKCOPY
prompts you to swap disks as necessary.
Using one drive for copying
When you use a single drive as both the source and destination drive,
DISKCOPY stores an image of the source disk in the directory specified by
the TEMP environment variable. If there is not enough space on that drive to
contain the source-disk image, you might have to swap floppy disks. DISKCOPY
prompts you each time you should insert a disk in the drive. DISKCOPY reads
from the source disk, writes to the destination disk, and prompts you to
insert the source disk again. This process continues until the entire disk
has been copied.
Avoiding disk fragmentation
Because DISKCOPY makes an exact copy of the source disk on the destination
disk, any fragmentation on the source disk is transferred to the destination
disk. Fragmentation is the presence of small areas of unused disk space
between existing files on a disk.
A fragmented source disk can slow down the finding, reading, or writing of
files. To avoid transferring fragmentation from one disk to another, use
either the COPY command or the XCOPY command to copy your disk. Because COPY
and XCOPY copy files sequentially, the new disk is not fragmented.
Copying Startup disks
If you use the DISKCOPY command to copy a startup disk, the copy will also
be a startup disk. If you use COPY or XCOPY to copy a startup disk, the copy
usually will not be a startup disk.
DISKCOPY exit codes
The following list shows each exit code (ERRORLEVEL parameter) and gives a
brief description of its meaning:
0 The copy operation was successful.
1 A nonfatal read/write error occurred.
2 The user pressed CTRL+C to stop the process.
3 A critical error occurred.
4 An initialization error occurred.
You can use the ERRORLEVEL parameter on the IF command line in a batch
program to process exit codes returned by DISKCOPY. For an example of a
batch program that processes exit codes, see the <CHOICE> command.
|