TREEDUPL TREEDUPL TREEDUPL TREEDUPL Directory Tree Duplicator Utility Reference Manual June 1986 This document describes the TREEDUPL Directory Tree Duplicator Utility. This utility is unlicensed and unsupported. Revision/Update Information: This is a new manual. Operating System and Version: MS-DOS* version 2.11 or later. Software Version: TREEDUPL version 2.0. NOT NOT NOT Support: THIS SOFTWARE IS NOT SUPPORTED BY DIGITAL EQUIPMENT CORPORATION. Direct questions and comments to: Brian Hetrick ZKO1-3/J10 Digital Equipment Corporation 110 Spit Brook Road Nashua NH 03062-2698 USA * MS is a trademark of Microsoft Corporation. Digital Equipment Corporation Maynard Massachusetts June 1986 The information in this document is subject to change without notice and should not be construed as a commitment by Digital Equipment Corporation. Digital Equipment Corporation assumes no responsibility for any errors that may appear in this document. The software described in this document is unlicensed and unsupported. Digital Equipment Corporation assumes no responsibility for the use or Digital Equipment Corporation assumes no responsibility for the use or Digital Equipment Corporation assumes no responsibility for the use or Digital Equipment Corporation assumes no responsibility for the use or reliability of this software. reliability of this software. reliability of this software. reliability of this software. This software is provided "as is," without any warranty of any kind, express or implied. Digital Equipment Corporation will not be liable in any event for any damages including any loss of data, profit, or savings, claims against the user by any other party, or any other incidental or consequential damages arising out of the use of, or inability to use, this software, even if Digital Equipment Corporation is advised of the possibility of such damage. This documentation and the software it describes have been placed into the public domain by Digital Equipment Corporation. The following are trademarks of Digital Equipment Corporation: DEC MASSBUS RSX VAX DECmate PDP RT VAXcluster DECnet P/OS ULTRIX VMS DECUS Professional ULTRIX-32 VT DECwriter Rainbow ULTRIX-32M Work Processor DIBOL RSTS UNIBUS _ _ _ _ _ _ _ | | | | | | | | |d|i|g|i|t|a|l| |_|_|_|_|_|_|_| Table of Contents Table of Contents Table of Contents Table of Contents Page Preface v Intended Audience v Structure of This Document v Associated Documents v Conventions Used in This Document vi Acknowledgments vi Summary 1 Format 1 Command Qualifiers 1 Command Parameters 1 Usage 1 Invoking 1 Exiting 1 Directing Output 2 Description 3 Invoking the Directory Tree Duplicator Utility 4 Restrictions 4 Command Qualifiers 6 /ACCUMULATE Command Qualifier 6 Format 6 Description 6 Example 6 /LOG Command Qualifier 8 Format 8 Description 8 Example 8 Examples 9 Backing Up a Hard Disk to a DECnet-DOS Virtual Disk 9 Restoring a Hard Disk from a DECnet-DOS Virtual Disk 10 Constructing the Bootable Diskette Containing DECnet-DOS 10 Restoring the Hard Disk from a Virtual Disk Used as a Current Copy 12 Restoring the Hard Disk from a Virtual Disk Used as an Accumulative Copy 13 Duplicating a Diskette 14 Deleting a Directory Tree 15 Directory Tree Duplicator Preface Preface Preface Preface Preface Intended Audience Intended Audience Intended Audience Intended Audience This manual is intended for all MS-DOS and DECnet-DOS users. Structure of This Document Structure of This Document Structure of This Document Structure of This Document This document has four major sections: o The Summary section is an overview of the Directory Tree Duplicator Utility and is intended as a quick reference guide. The Format subsection describes the command that invokes the Directory Tree Duplicator Utility, listing all command qualifiers and parameters. The Usage subsection describes how to invoke the Directory Tree Duplicator Utility, how to redirect output, and any restrictions that you should be aware of. o The Description section explains how to use the Directory Tree Duplicator Utility. o The Command Qualifier section describes each command qualifier. Command qualifiers appear in alphabetical order. o The Examples section contains examples of common operations that you perform with the Directory Tree Duplicator Utility. Associated Documents Associated Documents Associated Documents Associated Documents To use the Directory Tree Duplicator Utility, you should also be familiar with the following manual: ______ ______ _____ ____ _________ ______ o MS-DOS User's Guide, or Disk Operating System manual, as appropriate To use the Directory Tree Duplicator Utility in conjunction with DECnet-DOS virtual disks, you should also be familiar with the following manual __________ ______ _____ o DECnet-DOS User's Guide v Directory Tree Duplicator Preface Conventions Used in This Document Conventions Used in This Document Conventions Used in This Document Conventions Used in This Document Convention Meaning TREEDUPL E:\ G:\ TREEDUPL E:\ G:\ TREEDUPL E:\ G:\ E>TREEDUPL E:\ G:\ Command examples show all output lines or prompting characters that the system prints or displays in normal type. All bold bold bold user-entered commands are shown in bold type. /[NO]LOG Square brackets indicate that the enclosed item is optional. The symbol indicates that you must press the key labeled CTRL while you simultaneously press another key, for example, . Acknowledgments Acknowledgments Acknowledgments Acknowledgments The TREEDUPL Directory Tree Duplicator Utility uses the public domain command line parsing package written by Bela Lubkin of Borland International Inc. vi Directory Tree Duplicator Summary Summary Summary Summary Summary The TREEDUPL program copies or duplicates all files and directories in an entire directory tree. Format Format Format Format __________ __________ _________ TREEDUPL sourceroot targetroot [qualifier] Command Qualifiers Defaults Command Qualifiers Defaults Command Qualifiers Defaults Command Qualifiers Defaults /[NO]ACCUMULATE /ACCUMULATE /[NO]LOG /LOG Command Parameters Command Parameters Command Parameters Command Parameters __________ sourceroot Specifies the name for the root of the directory tree to be copied or duplicated. __________ targetroot Specifies the name for the root of the directory tree into __________ which the tree specified by sourceroot is to be copied or duplicated. Usage Usage Usage Usage Invoking Invoking Invoking Invoking You invoke the Directory Tree Duplicator Utility with the TREEDUPL command. Exiting Exiting Exiting Exiting You exit the Directory Tree Duplicator Utility normally by waiting until processing is complete. The Directory Tree Duplicator Utility will return control to the command interpreter when processing is complete. You can exit the Directory Tree Duplicator Utility abnormally by typing , if the /NOLOG command qualifier has not been given or if the MS-DOS BREAK parameter is ON. 1 Directory Tree Duplicator Summary Directing Output Directing Output Directing Output Directing Output By default, messages from the Directory Tree Duplicator Utility are directed to the console device. Such messages may be directed to another device or a file with the I/O redirection facilities of the command interpreter. 2 Directory Tree Duplicator Description Description Description Description Description The Directory Tree Duplicator Utility is a command-line oriented program used to copy all directories and files in an entire directory tree to another directory, or to force one directory tree to duplicate another. Through the use of the Directory Tree Duplicator Utility, you can maintain a backup copy of your personal computer's hard disk in a DECnet-DOS virtual disk maintained an another node of a DECnet network, or duplicate the complete contents of a diskette on another diskette, or delete an entire directory tree, or move an entire directory tree from one directory to another. Invoking the Directory Tree Duplicator Utility Invoking the Directory Tree Duplicator Utility Invoking the Directory Tree Duplicator Utility Invoking the Directory Tree Duplicator Utility The Directory Tree Duplicator Utility is invoked with the TREEDUPL command, followed by the name of the root directory of the source directory tree (the directory tree to be copied or duplicated), followed by the name of the root directory of the target directory tree (the directory tree to be produced). No wild card characters are allowed in either name. Command qualifiers may follow any of these components of the command. For example, the following command copies all directories and files on the volume in drive A to the volume in drive B: TREEDUPL A:\ B:\ TREEDUPL A:\ B:\ TREEDUPL A:\ B:\ E>TREEDUPL A:\ B:\ If a drive letter is specified, the directory is interpreted as residing on the volume in the specified drive. Otherwise, the directory is interpreted as residing on the volume in the current drive. If the directory name starts with a back slash (\), the directory name is interpreted as relative to the root directory of the volume. Otherwise, the directory name is interpreted as relative to the current directory on the volume. If the current directory on the volume in drive E is the root directory, and the current directory on the volume in drive G is \E_SAVE, then the command: TREEDUPL E: G: TREEDUPL E: G: TREEDUPL E: G: E>TREEDUPL E: G: will copy all directories and files on the entire volume in drive E into a directory tree rooted at the directory \E_SAVE of the volume in drive G. Except in the root directory of a volume, a single period (.) in the place of the first directory name refers to the current directory, and two periods (..) refers to the parent of the current directory. In the root directory of a volume, these 3 Directory Tree Duplicator Description cannot be used. A single back slash always refers to the root directory of a volume. The Directory Tree Duplicator Utility copies all directories and files from the source directory tree to the target directory tree. However, the Directory Tree Duplicator Utility will attempt not to copy files which are apparently already at the appropriate position in the target directory tree. For non-directory files, the Directory Tree Duplicator Utility will not copy a file in the source directory tree (the "source file") if: o There is a file of the same name in the corresponding position in the target directory tree (the "target file"); o The sizes of the source file and the target file are equal; o The modification dates and times of the source file and the target file are equal. If there is a target file that appears to be the same as the source file based on these characteristics, then its contents are not modified, but its file attributes (read-only, system, hidden, and archive) are set to be the same as those of the source file. If there is a target file that appears to be different from the source file based on these characteristics, then the target file is deleted and the source file is copied to its place. The file size, file attributes (read only, hidden, system, and archive), and file modification date and time of the copy are set to duplicate those of the source file. For a directory in the source directory tree, the Directory Tree Duplicator Utility will create a corresponding directory in the target directory tree unless one already exists. The file attributes of the new or existing directory are set to be the same as those of the directory in the source directory tree. The Directory Tree Duplicator Utility can also delete all files in the target directory tree that are not in the source directory tree. The /ACCUMULATE command qualifier controls this behavior. By default, the Directory Tree Duplicator Utility issues messages describing its actions. These messages can be suppressed. The /LOG command qualifier controls this behavior. Restrictions Restrictions Restrictions Restrictions The Directory Tree Duplicator Utility cannot be used to copy a source directory tree into a target directory tree whose root is 4 Directory Tree Duplicator Description in the source directory tree itself. For example, the command: TREEDUPL E:\SUBDIR1 E:\SUBDIR1\SUBDIR2 TREEDUPL E:\SUBDIR1 E:\SUBDIR1\SUBDIR2 TREEDUPL E:\SUBDIR1 E:\SUBDIR1\SUBDIR2 E>TREEDUPL E:\SUBDIR1 E:\SUBDIR1\SUBDIR2 would fail as the \SUBDIR1\SUBDIR2 directory is in the directory tree having \SUBDIR1 as its root. 5 Directory Tree Duplicator Command Qualifiers /ACCUMULATE Command Qualifier /ACCUMULATE Command Qualifier /ACCUMULATE Command Qualifier /ACCUMULATE Command Qualifier Format Format Format Format /ACCUMULATE /NOACCUMULATE Description Description Description Description By default, the Directory Tree Duplicator Utility retains all files and directories in the target directory, unless there is a corresponding file in the source directory tree that is different from the file or directory in the target directory. However, the Directory Tree Duplicator Utility can "prune" the target directory tree, that is, delete files and directories that do not appear in the source directory tree. The /ACCUMULATE command qualifier controls this behavior. If you specify /NOACCUMULATE, files and directories in the target directory that do not appear in the source directory are deleted. If you omit the qualifier or specify /ACCUMULATE, files in the target directory that do not appear in the source directory are retained. If you specify /NOACCUMULATE, even files and directories in the target directory tree with the read-only attribute are deleted if they do not exist in the source directory tree. Example Example Example Example TREEDUPL A:\ B:\ /NOACCUMULATE TREEDUPL A:\ B:\ /NOACCUMULATE TREEDUPL A:\ B:\ /NOACCUMULATE E>TREEDUPL A:\ B:\ /NOACCUMULATE TREEDUPL version 2.0 Copied A:\AUTOEXEC.BAT to B:\AUTOEXEC.BAT Copied A:\COMMAND.COM to B:\COMMAND.COM Copied A:\CONFIG.SYS to B:\CONFIG.SYS Copied A:\IO.SYS to B:\IO.SYS Copied A:\MSDOS.SYS to B:\MSDOS.SYS Deleted B:\TREEDUPL\CLA.PAS Deleted B:\TREEDUPL\TREEDUPL.COM Deleted B:\TREEDUPL\TREEDUPL.PAS Deleted B:\TREEDUPL E> With this command, the directory tree of the volume mounted in drive A is exactly replicated on the volume mounted in drive B. Files on the volume in drive A that are not on the volume in 6 Directory Tree Duplicator Command Qualifiers drive B are copied onto the volume in drive B; files on the volume in drive B that are not on the volume in drive A are deleted. In the example, the \TREEDUPL directory of the volume in drive B did not appear on the volume in drive A, and so the directory's contents and then the directory itself were deleted. 7 Directory Tree Duplicator Command Qualifiers /LOG Command Qualifier /LOG Command Qualifier /LOG Command Qualifier /LOG Command Qualifier Format Format Format Format /LOG /NOLOG Description Description Description Description By default, the Directory Tree Duplicator Utility produces messages describing its actions. These messages are produced on the standard output, which is normally directed to the console. The /LOG command qualifier controls the production of these messages. If you specify /NOLOG, no messages are produced. If you omit the qualifier or specify /LOG, messages are produced whenever a file is copied or deleted, a directory is created or deleted, and whenever a file's attributes are modified. Example Example Example Example TREEDUPL A:\ B:\ /NOLOG TREEDUPL A:\ B:\ /NOLOG TREEDUPL A:\ B:\ /NOLOG E>TREEDUPL A:\ B:\ /NOLOG TREEDUPL version 2.0 E> With this command, messages describing the actions taken by the Directory Tree Duplicator Utility to copy the files on the volume in drive A to the volume in drive B are not issued. 8 Directory Tree Duplicator Examples Examples Examples Examples Examples Backing Up a Hard Disk to a DECnet-DOS Virtual Disk Backing Up a Hard Disk to a DECnet-DOS Virtual Disk Backing Up a Hard Disk to a DECnet-DOS Virtual Disk Backing Up a Hard Disk to a DECnet-DOS Virtual Disk You can make a backup copy of the data on your hard disk using a DECnet-DOS virtual disk as the backup medium. The DECnet-DOS virtual disk will then be backed up to archival storage (for example, magnetic tape) under the standard backup procedures for the remote node on which the virtual disk resides. This form of backup can be unattended, as it is not necessary to change volumes in a small capacity diskette drive. _______ You should first decide whether you want to keep a current copy ____________ of the data on your disk, or an accumulative copy of the data on your disk. A current copy will have only the data on your disk as of the most recent backup; an accumulative copy will retain old files that you have deleted on your disk. However, an accumulative copy will not retain old versions of files that still exist; only the most recent version of any file will is retained. An accumulative copy will require a larger virtual disk than will a current copy. Also, an accumulative copy is more difficult to restore from than is a current copy. Similarly, if you have several hard disks, you should decide whether to back these up into a single virtual disk or into several virtual disks. Backing up several hard disks into a single virtual disk will require a larger virtual disk than will backing up each hard disk into separate virtual disks. Before backing up your hard disk's data for the first time, you must create the DECnet-DOS virtual disk. You do this using the _ _ _ DECnet-DOS NDU (Network Device Utility) CREATE command. For example, the command: NDU CREATE DRIVE G NODE EVER11 NDISK HDBACKUP.DSK MAX 32 NDU CREATE DRIVE G NODE EVER11 NDISK HDBACKUP.DSK MAX 32 NDU CREATE DRIVE G NODE EVER11 NDISK HDBACKUP.DSK MAX 32 E>NDU CREATE DRIVE G NODE EVER11 NDISK HDBACKUP.DSK MAX 32 creates a 32 megabyte virtual disk in the default directory of the account specified by the default access control string for node EVER11, and makes that disk available through MS-DOS drive letter G. After using the NDU CREATE command, to create a new virtual disk, or the NDU OPEN command, to access an already existing virtual disk, you can backup your hard disk contents by using the Directory Tree Duplication Utility to copy the hard disk contents to the virtual disk. For example, the commands: 9 Directory Tree Duplicator Examples TREEDUPL E:\ G:\E_BACKUP /NOLOG TREEDUPL E:\ G:\E_BACKUP /NOLOG TREEDUPL E:\ G:\E_BACKUP /NOLOG E>TREEDUPL E:\ G:\E_BACKUP /NOLOG TREEDUPL version 2.0 TREEDUPL F:\ G:\F_BACKUP /NOLOG TREEDUPL F:\ G:\F_BACKUP /NOLOG TREEDUPL F:\ G:\F_BACKUP /NOLOG E>TREEDUPL F:\ G:\F_BACKUP /NOLOG TREEDUPL version 2.0 copy all files and directories on the hard disk in drive E into the directory \E_BACKUP on the virtual disk currently accessed through drive letter G, and copies all files and directories on the hard disk in drive F into the directory \F_BACKUP on the virtual disk currently accessed through drive letter G. Because the /NOACCUMULATE command qualifier is not specified, accumulative copies of the data on the hard disks in drives E and F are made. Similarly, the commands: TREEDUPL/NOACCUMULATE E:\ G:\E_BACKUP /NOLOG TREEDUPL/NOACCUMULATE E:\ G:\E_BACKUP /NOLOG TREEDUPL/NOACCUMULATE E:\ G:\E_BACKUP /NOLOG E>TREEDUPL/NOACCUMULATE E:\ G:\E_BACKUP /NOLOG TREEDUPL version 2.0 TREEDUPL/NOACCUMULATE F:\ G:\F_BACKUP /NOLOG TREEDUPL/NOACCUMULATE F:\ G:\F_BACKUP /NOLOG TREEDUPL/NOACCUMULATE F:\ G:\F_BACKUP /NOLOG E>TREEDUPL/NOACCUMULATE F:\ G:\F_BACKUP /NOLOG TREEDUPL version 2.0 construct current copies of the data on the hard disks in drives E and F. Restoring a Hard Disk from a DECnet-DOS Virtual Disk Restoring a Hard Disk from a DECnet-DOS Virtual Disk Restoring a Hard Disk from a DECnet-DOS Virtual Disk Restoring a Hard Disk from a DECnet-DOS Virtual Disk You can restore the contents of a corrupted hard disk from a DECnet-DOS virtual disk which has been used as an accumulative or a current copy of the files and directories on your disk. As the hard disk may be unusable as a system device should this prove necessary, you will need to have on a diskette a system sufficient to restore the files and directories on the virtual disk to the hard disk. You can then use this diskette based system to restore the contents of the hard disk from the virtual disk copy. Constructing the Bootable Diskette Containing DECnet-DOS Constructing the Bootable Diskette Containing DECnet-DOS Constructing the Bootable Diskette Containing DECnet-DOS Constructing the Bootable Diskette Containing DECnet-DOS You must first construct a bootable diskette system that permits you to access DECnet-DOS virtual disks. First, format a system diskette; for example, the command: FORMAT A:/S FORMAT A:/S FORMAT A:/S E>FORMAT A:/S will construct a bootable diskette containing only the MS-DOS system on the diskette in drive A. Then, ensure that the necessary DECnet-DOS files are on the diskette. You may either install DECnet-DOS onto the diskette, or copy the DECnet-DOS files from your hard disk onto the diskette. In either case, the only purpose of this DECnet-DOS 10 Directory Tree Duplicator Examples installation is to access a virtual disk on a single remote node, so most DECnet-DOS utilities need not be included. For example, a bootable system diskette for a Rainbow 100A system to be used with a serial communications line that is dynamically switched to DDCMP protocol might contain the visible files: COMMAND.COM The MS-DOS command interpreter NDDRV.SYS Network disk driver FIX100A.COM Rainbow 100A interrupt structure fixup SCH.EXE DECnet-DOS scheduler DNP.EXE DECnet-DOS DECnet process NCP.EXE Network Control Program NCP.TXT Initialization commands for NCP NDU.EXE Network Device Utility CONFIG.SYS MS-DOS boot configuration commands AUTOEXEC.BAT Startup commands KERMIT.EXE Terminal emulation program DECNET Empty subdirectory TREEDUPL.COM The Directory Tree Duplicator Utility The contents of CONFIG.SYS might be: DEVICE=NDDRV.SYS FILES=20 BUFFERS=32 while the contents of AUTOEXEC.BAT might be: PATH A:\ FIX100A SCH DNP A:\DECNET\ Complete installation of DECnet-DOS by booting this diskette, invoking NCP to accept the commands in NCP.TXT, and defining the transmit and receive passwords, if any, and defining the adjacent node and the remote node on which the virtual disk resides. You should test this diskette by rebooting from it to install the now initialized DECnet network, and bring up the DECnet line in the normal fashion. Then use the NDU OPEN command to attempt to access the virtual disk you are using as a backup of your hard disk. When you can access the files on the virtual disk using only the system on the diskette, you have created the bootable diskette containing DECnet-DOS that can be used to restore the hard disk should it become corrupt. 11 Directory Tree Duplicator Examples Restoring the Hard Disk from a Virtual Disk Used as a Current Restoring the Hard Disk from a Virtual Disk Used as a Current Restoring the Hard Disk from a Virtual Disk Used as a Current Restoring the Hard Disk from a Virtual Disk Used as a Current Copy Copy Copy Copy To restore the contents of the hard disk from a virtual disk, you must first ensure that the hard disk is in a state acceptable to MS-DOS. This may require that you format the disk, and, if the hard disk is to be bootable, install the MS-DOS system. When the hard disk has been prepared, you must boot the diskette containing DECnet-DOS, bring up the DECnet line in the normal fashion, and use the NDU utility to make accessible the virtual disk containing the current copy of the hard disk's contents. If files or directories have been stored onto the hard disk which are not to be destroyed (for example, the MS-DOS operating system), you must now use the standard MS-DOS COPY and MKDIR commands, or the Directory Tree Duplicator Utility, to ensure that these files and directories are reflected in the virtual disk. For example, the command: TREEDUPL E:\ I:\ /NOLOG TREEDUPL E:\ I:\ /NOLOG TREEDUPL E:\ I:\ /NOLOG A>TREEDUPL E:\ I:\ /NOLOG TREEDUPL version 2.0 would ensure that restoring the files and directories on the virtual disk accessible through drive letter I to the hard disk in drive E would not overwrite the files and directories currently on the hard disk in drive E. Now, you can copy the files and directories on the virtual disk to the hard disk using the Directory Tree Duplicator Utility. For example, the command: TREEDUPL I:\ E:\ /NOLOG TREEDUPL I:\ E:\ /NOLOG TREEDUPL I:\ E:\ /NOLOG A>TREEDUPL I:\ E:\ /NOLOG TREEDUPL version 2.0 would copy all files on the virtual disk accessible through drive letter I to the hard disk in drive E. At this point, the files and directories have been restored. You can now boot the computer in your usual fashion and proceed with the newly restored hard disk. Restoring the Hard Disk from a Virtual Disk Used as an Restoring the Hard Disk from a Virtual Disk Used as an Restoring the Hard Disk from a Virtual Disk Used as an Restoring the Hard Disk from a Virtual Disk Used as an Accumulative Copy Accumulative Copy Accumulative Copy Accumulative Copy To restore the contents of the hard disk from a virtual disk, you must first ensure that the hard disk is in a state acceptable to MS-DOS. This may require that you format the disk, and, if the hard disk is to be bootable, install the MS-DOS system. 12 Directory Tree Duplicator Examples When the hard disk has been prepared, you must boot the bootable diskette containing DECnet-DOS, bring up the DECnet line in the normal fashion, and use the NDU utility to make accessible the virtual disk containing the accumulative copy of the hard disk's contents. If files or directories have been stored onto the hard disk which are not to be destroyed (for example, the MS-DOS operating system), you must now use the standard MS-DOS COPY and MKDIR commands, or the Directory Tree Duplicator Utility, to ensure that these files and directories are reflected in the virtual disk. For example, the command: TREEDUPL E:\ I:\ /NOLOG TREEDUPL E:\ I:\ /NOLOG TREEDUPL E:\ I:\ /NOLOG A>TREEDUPL E:\ I:\ /NOLOG TREEDUPL version 2.0 would ensure that restoring the files and directories on the virtual disk accessible through drive letter I to the hard disk in drive E would not overwrite the files and directories currently on the hard disk in drive E. If the files and directories on the virtual disk will fit onto the hard disk, the simplest procedure is to restore the entire contents of the virtual disk to the hard disk and then to individually delete files and directory trees that are not needed. For example, the command: TREEDUPL I:\ E:\ /NOLOG TREEDUPL I:\ E:\ /NOLOG TREEDUPL I:\ E:\ /NOLOG A>TREEDUPL I:\ E:\ /NOLOG TREEDUPL version 2.0 would copy all files on the virtual disk accessible through drive letter I to the hard disk in drive E. The unwanted files and directories could then be deleted with the standard MS-DOS DEL and RMDIR commands, and entire unwanted directory trees could then be deleted with the Directory Tree Duplicator Utility. If the files and directories on the virtual disk will not fit onto the hard disk, then copying all files and directories on the virtual disk to the hard disk is not possible. You must manually direct a process in which only some of the files and directories on the virtual disk are copied onto the hard disk. The first method of copying only some files and directories on the virtual disk onto the hard disk is to copy individual files and directory trees from the virtual disk to the hard disk using the standard MS-DOS MKDIR and COPY commands, and the Directory Tree Duplicator Utility. The second method of copying only some files and directories on the virtual disk onto the hard disk is to delete 13 Directory Tree Duplicator Examples individual files and directory trees from the virtual disk, using the standard MS-DOS DEL and RMDIR commands, and the Directory Tree Duplicator Utility, and then copy all remaining files and directories on the virtual disk to the hard disk. Since this process destroys some of the contents of the virtual disk, you may want to use the DECnet network remote node's file copy command to create a temporary duplicate of the virtual disk. This temporary duplicate of the virtual disk can be used as the virtual disk from which the restoration is to take place: individual files and directory trees may be deleted freely from the temporary duplicate, without affecting the contents of the original virtual disk. When all files and directories of interest have been restored, you can boot the computer in your usual fashion and proceed with the newly restored hard disk. Duplicating a Diskette Duplicating a Diskette Duplicating a Diskette Duplicating a Diskette You can duplicate the contents of a diskette using the Directory Tree Duplicator Utility. First, place the diskette to be duplicated into one diskette drive. Then, place the diskette onto which the duplicate is to be made into a second diskette drive. It is advisable to format the second diskette, but this step is often not necessary. Then use the TREEDUPL command with the /NOACCUMULATE command qualifier to duplicate the contents of the first diskette onto the second diskette. For example, if the diskette to be duplicated has been placed into drive A, and the diskette to receive the copy has been placed into drive B, then the command: TREEDUPL A:\ B:\ /NOACCUMULATE /NOLOG TREEDUPL A:\ B:\ /NOACCUMULATE /NOLOG TREEDUPL A:\ B:\ /NOACCUMULATE /NOLOG E>TREEDUPL A:\ B:\ /NOACCUMULATE /NOLOG will duplicate the contents of the diskette in drive A onto the diskette in drive B. It is possible to duplicate the contents of a diskette even if you have only one diskette drive, as long as you have a hard disk or DECnet-DOS virtual disk with enough free space. First, duplicate the diskette into a newly created directory on the hard disk or DECnet-DOS virtual disk; then duplicate the directory on the hard disk or DECnet-DOS virtual disk. For example, the commands: MKDIR E:\DISKCOPY MKDIR E:\DISKCOPY MKDIR E:\DISKCOPY E>MKDIR E:\DISKCOPY 14 Directory Tree Duplicator Examples TREEDUPL A:\ E:\DISKCOPY/NOLOG TREEDUPL A:\ E:\DISKCOPY/NOLOG TREEDUPL A:\ E:\DISKCOPY/NOLOG E>TREEDUPL A:\ E:\DISKCOPY/NOLOG TREEDUPL version 2.0 create a directory on the disk in drive E, and then copy the contents of the diskette in drive A into that directory. The subsequent command: TREEDUPL/NOACCUMULATE/NOLOG E:\DISKCOPY A:\ TREEDUPL/NOACCUMULATE/NOLOG E:\DISKCOPY A:\ TREEDUPL/NOACCUMULATE/NOLOG E:\DISKCOPY A:\ E>TREEDUPL/NOACCUMULATE/NOLOG E:\DISKCOPY A:\ TREEDUPL version 2.0 will copy the directories and files onto the diskette in drive A. Deleting a Directory Tree Deleting a Directory Tree Deleting a Directory Tree Deleting a Directory Tree You can delete an entire directory tree, even if it contains read-only, hidden, or system files, using the Directory Tree Duplicator Utility. You first create an empty directory, then copy it to the root of the directory tree to be deleted using the /NOACCUMULATE command qualifier, then remove both the empty directory you created and the now-empty directory. For example, to remove the directory tree rooted at \WORK\QRTR1, you could issue the commands: MKDIR \EMPTY MKDIR \EMPTY MKDIR \EMPTY E>MKDIR \EMPTY TREEDUPL/NOLOG/NOACCUMULATE \EMPTY \WORK\QRTR1 TREEDUPL/NOLOG/NOACCUMULATE \EMPTY \WORK\QRTR1 TREEDUPL/NOLOG/NOACCUMULATE \EMPTY \WORK\QRTR1 E>TREEDUPL/NOLOG/NOACCUMULATE \EMPTY \WORK\QRTR1 TREEDUPL version 2.0 RMDIR \EMPTY RMDIR \EMPTY RMDIR \EMPTY E>RMDIR \EMPTY RMDIR \WORK\QRTR1 RMDIR \WORK\QRTR1 RMDIR \WORK\QRTR1 E>RMDIR \WORK\QRTR1 You must use the /NOACCUMULATE command qualifier, to delete the directories and files in the directory tree rooted at \WORK\QRTR1; you may optionally use the /NOLOG command qualifier to suppress the printing of messages naming the files as they are deleted. 15