VMS_SYSLOST_RECOVER.MEM ----------------------- Background: ---------- [SYSLOST] is used by analyze/disk/repair to hold files which have gotten separated from the directory indicated by the "backlink" file id in INDEXF.SYS. Somehow, files and directories which have been moved to [SYSLOST] can still appear in their appropriate directory files as well! The actual directory link inside INDEXF.SYS points to the [SYSLOST] entry. It takes a bit of care to restore the backlink in INDEXF.SYS. We must remove (*NOT DELETE*) the seemingly correct link in the directory file, because it does not appear inside INDEXF.SYS. Then we rename the [SYSLOST] file, thereby changing its directory link inthe correct manner. Two procedures have been written to help with this task: 1) nstx$:[data_management]syslost_recover.com and 2) nstx$:[data_management]syslost_preprocess.com NSTX$:[data_management]syslost_recover.com ------------------------------------------ Usage: @syslost_recover [syslost filename] [dest.directory] \ Wildcards ok Operation: 1) looks for "syslost filename" in [dest.directory] 2) compares fileid of the two files 3) if fileids match (i.e. they are the identical file) the entry is removed from [dest.directory] and then the "syslost" file is renamed to [dest.directory], preserving the version number of the original [dest.directory] filename. Example: $ @syslost_recover NSTX1:[SYSLOST]nstx_108233.* [nstx_arc.nstx.10.82] NSTX$:[data_management]syslost_preprocess.com --------------------------------------------- This procedure deals with ".DIR" files in [syslost]. You might wind up with multiple versions of a ".DIR" file, but each is probably unique (e.g. "10.DIR" orphaned from different NSTX1:[nstx_arc.*] directories). VMS pays attention only to rev 1 of any .DIR file (10.DIR;1), so it's not so easy to discover where a particular .DIR-file belongs by examining its contents. (also, a .DIR file might have no files in it). This procedure uses file-ids to match up directory files in [SYSLOST] with the directories where they belong. Usage: @syslost_preprocess [syslost ".DIR" file spec] \ directory files only. Wildcards ok. Operation: 1) For each directory file specified, search through entire disk for similarly-named files; 2) Compare file-ids of the matching directory files; 3) If they match, SUCCESS! Type out the appropriate "@syslost_recover" command line to cut/paste onto the command line. Example: $ @syslost_preprocess NSTX1:[SYSLOST]10.dir;*