Google
 

Trailing-Edge - PDP-10 Archives - decuslib10-10 - 43,50524/d2d.rnd
There are no other files named d2d.rnd in the archive.
.npa
.ts 50
D2D - Disk To Disk Pack Copy;	27-Jul-81:
.sk
D2D (disk to disk) copies an entire disk pack to another disk pack. 
Using Super-USETI and Super-USETO (SUSET.) instead of LOOKUP
and ENTER, as well as performing its own file space allocation and
Storage Allocation Table (SAT) management, results in a fast
copy. At the Univesity of Texas at Austin, (UTAustin), copies
of RP06s using FUR which run 4 hours are performed in 40 minutes with D2D.
Unlike "image" copy programs which also use SUSET. but simply
copy block to block and result in a useless BADBLK.SYS, D2D
creates a refreshed pack with a valid BADBLK.SYS.
.sk
D2D runs in two phases; the first is to build a map of the pack 
being copied from. There is a entry in the map for every file,
including the MFD, UFDs, and SFDs. Each entry (one word) has the format:
.i 3;1) SIXBIT/filename/
.i 3;2) SIXBIT/extension/,,number of files in directory
.i 4;(for MFD, UFDs and SFDs; zero otherwise)
.i 3;3) Block address of file on original pack
.i 3;4) Block address of file on target pack
.i 3;5) Block address on target pack of UFD
.i 4;to which file belongs
.i 3;6) Pointer to map entry of first file in directory
.i 4;(directory entries only; others zero)
.i 3;7) Number of blocks in file
.sk
As the map is built files are allocated new addresses on the 
pack. D2D maintains it's own SAT; files are allocated contiguous space
only. Both the SATs and the Map are kept in core.
Phase two uses the Map to read files from the pack being copied from
and transfers them to their new address on the target pack. It is essential
that the disk structure of the pack being copied from be static; hence
D2D should only be run on a stand alone system. In-core buffering is 
used in the transfer phase; at UTAustin an RP06 copy requires
about 300 pages of physical core.

.sk;SETTING UP A TARGET PACK
.sk
D2D uses a pack formatted by TWICE.
The pack may be given any Structure Name; D2D will use the Structure
Name found in the HOME block of the original pack to build RIBs and
update the HOME block of the target pack.
.sk
The Bits per Cluster Count should be set to 15. D2D uses a single
RIB Retrieval Pointer when building RIBs on the target pack
so the RIB Retrieval Pointer's Cluster Count must be assigned 
enough bits to 
represent the largest file that will be copied. With 15 bits and 3 blocks
per cluster the Cluster Count can represent files of 98,301 blocks.
.sk
RUNNING D2D
.sk
You have formatted a pack with TWICE, the system is stand alone,
the packs to be copied from and to are mounted.
While logged into the Operator job do,
.i 3;RUN D2D
.i 3;COPY FROM: give structure name
.i 3;COPY   TO: give structure name
.i 3;I.D. OF PACK COPYING TO: give physical unit I.D.
.i 4;(this is safety precaution)
.sk
D2D exits when done, dumping the Map into file DSK:MAP.FIL
and the SAT into DSK:SAT.FIL. Both are binary files and 
intended for debugging or copy verification. Readable 
reports of these two files can be generated by running 
DMPMAP.SAI (report written to MAP.LST) and DMPSAT.SAI (report
written to SAT.LST) respectively.
SAT.LST is similar to RIPOFFs /PS (print SAT) report and 
can be compared with this report to confirm the SATs integrity.
.sk
Before trying to do a directory of the newly copied target pack
you must dismount and remount it to force the new
HOME blocks to be read into core by the monitor.
You may now run DSKRAT on the pack; this is advisable until 
you are confident D2D is correctly copying packs
on your system.
D2D creates some lost blocks; it does not use the
system directories set up by TWICE but rather rebuilds these
itself. This is done to avoid the possibility that the directory,
as set up by TWICE,
may not be large enough and would have to be extended, possibily
using blocks not contiguous. D2D can't do this yet. By rebuilding
the system directories D2D can allocate the needed number of 
contiguous blocks from the outset.
After running DSKRAT you can free-up these lost blocks by
deleting LSTBLK.*.
The lost blocks should cause no problems if not deleted.
.sk
BEWARE
.sk
This section is a check list of important infomation (some mentioned
previously),
known problems, and possible enhancements.
.sk
D2D allocates only contiguous space to files on the target
pack; this causes some problems:
a file cannot be allocated space from two different SAT blocks
and there must always be a sufficiently large contiguous chunk of space
for the file.
This will probably only be a problem if the packs being copied
are VERY full.
Also, to avoid the possibility that a system directory (as set up
by TWICE), may not be large enough and would have to be extended,
possibly using non-contiguous blocks, D2D re-builds the system
directories elsewhere, allocating the needed number of contiguous
blocks from the outset. The HOME blocks and SYS UFD must then
be updated to point to the new system directories. This results
in the old system directories becoming lost blocks.
.sk
After D2D finishes dismount and remount the pack before trying
to do anything with it; this forces the new HOME blocks to be read
into core.
.sk
When setting up the target pack with TWICE, specify 15 bits
for the RIB Retrieval Pointer's Cluster Count.
See SETTING UP A TARGET PACK above.
.sk
.sk
D2D should be run stand alone only; this assures a static disk 
structure on the pack being copied from.
.sk
The SATs, disk Map, and as much buffering as is possible
is done in-core.Expect to use from 100 to 300 pages of physical core.
.sk
D2D computes logical block addresses by multiplying
Compressed File Pointers (CFP), by the blocks per cluster,
which is word HOMPBC in the HOME block. This is satisfactory
as long as Super Cluster size = Cluster size and a disk structure consists
of only a single physical unit.
.sk
.sk
The following files are not copied by D2D:
SAT.SYS, HOME.SYS, SWAP.SYS, MAINT.SYS, BADBLK.SYS, CRASH.EXE,
SWAP.EXE, and RECOVE.SYS.
If you want these files on the new pack you must put them
there with TWICE.
.sk
Has only been used to copy RP06s and RP04s at UTAustin.
.sk
If you do not want the MAP.FIL and SAT.FIL to be written as 
D2D exits, remove the calls to the routines that do this:
.i 3;PUSHJ P,DMPMAP
.i 3;PUSHJ P,DMPSAT
.br;after label UPDSUF.