home *** CD-ROM | disk | FTP | other *** search
/ Frozen Fish 1: Amiga / FrozenFish-Apr94.iso / bbs / alib / d1xx / d108 / zoo.lha / Zoo / fiz.zoo / fiz.doc < prev    next >
Text File  |  1987-06-28  |  7KB  |  175 lines

  1.                           Fiz -- a Fix Zoo Utility
  2.                                      by
  3.                                 Rahul Dhesi
  4.  
  5.  
  6. Fiz version 1.00 for is a public domain utility that can help you extract
  7. data from a damaged Zoo archive.  It is used in conjunction with Zoo version
  8. 1.41 or later.  Fiz is invoked as follows:
  9.  
  10.      fiz archive[.zoo]
  11.  
  12. Fiz searches through the archive for directory entries.  For each directory
  13. entry found, it prints the position of the directory entry within the ar-
  14. chive (a decimal number), the associated path prefix if any, the short
  15. filename, and the long filename if any.  The first directory entry listed
  16. (with a meaningless filename) is usually the archive header and should be
  17. ignored.  The last directory entry listed (with null directory and file
  18. names) is the trailing null directory entry that every Zoo archive contains
  19. and this too should be ignored.
  20.  
  21. Fiz converts any unprintable characters encountered in a filename to printa-
  22. ble equivalents before printing them.  Control characters are converted to
  23. corresponding digraphs (e.g. control A becomes "^A") and characters with the
  24. eighth bit set are printed preceded by a tilde ("~").  If Fiz detects a
  25. corrupted directory entry CRC (not the file data CRC), it indicates so.
  26.  
  27. Make a record of Fiz's output by redirecting it to a file.  Then list the
  28. undamaged files using Zoo version 1.41 or later as follows:
  29.  
  30.      zoo l@n archive[.zoo]
  31.  
  32. where n is a position within the damaged Zoo archive, obtained from the
  33. output of Fiz.  If n is properly chosen, the damaged portion of the Zoo
  34. archive will be ignored and all remaining undamaged filenames will be
  35. listed.  To extract undamaged files use the command:
  36.  
  37.      zoo x@n archive[.zoo]
  38.  
  39. The @n option may be used in combination with all other legal options.  For
  40. example, the command
  41.  
  42.      zoo xdd@309 jkl *.c
  43.  
  44. will extract only deleted files matching "*.c", beginning at position 309
  45. within the archive "jkl.zoo".  Similarly, the command
  46.  
  47.      zoo La@8992 /new/*.zoo /doc/*.zoo
  48.  
  49. will list the contents of all Zoo archives in /new and /doc directories,
  50. beginning the listing of each archive at position 8992.
  51.  
  52.  
  53.                           SAMPLE RUN UNDER MS-DOS
  54.  
  55. A damaged practice Zoo archive called "damaged.zoo" is supplied with Fiz.
  56. Attempting to get a listing with Zoo 1.41 gives the following result:
  57.  
  58.     Archive damaged.zoo:
  59.     Zoo:  WARNING:  Archive damaged.zoo:  Zoo 31.0 or later is needed to fully
  60.     manipulate this archive.
  61.     Zoo:  FATAL:  Archive damaged.zoo:  Directory entry in archive is invalid.
  62.     Zoo:  No files matched.
  63.     (The archive is empty.)
  64.  
  65. Zoo 31.0 is not due to be released until well into the 22nd century, so the
  66. archive header is clearly corrupted.
  67.  
  68. Here is the output from Fiz when it is used on this archive with the command
  69. "fiz damaged":
  70.  
  71.     ****************
  72.           20:   [~^K]
  73.     ****************
  74.           34:  [/xyz/usr/dhesi] [saying.fir] [saying.first] [*bad CRC*]
  75.     ****************
  76.          264:  [/xyz/usr/dhesi] [saying.sec] [saying.second] [*bad CRC*]
  77.     ****************
  78.          494:   [^A^B^C^D^E^F^I^J^K^L^M^N] [^K^S^J^D^I^E^J^L^D^N^F^K^E^I^I^U
  79.          ^U^F^L^F^J^K^L^Sjfdlksd] [*bad CRC*]
  80.     ****************
  81.          672:   [Another_.nam] [Another.file.with.a.long.name]
  82.     ****************
  83.          892:   [adage.3]
  84.     ****************
  85.         1337:   [adage.4]
  86.     ****************
  87.         1477:  [] [] []
  88.  
  89. The garbaged filename at position 20 is the archive header; we ignore it.
  90. Following that are six files, all of which except one seem to have meaning-
  91. ful filenames.  The first three directory entries seem to be corrupted,
  92. because Fiz has detected a bad CRC and indicated so.  However, it is still
  93. worth trying to recover data from them because the file data may still be
  94. undamaged.
  95.  
  96. Now, knowing the positions of the directory entries that Fiz could
  97. recognize, we can try listing the undamaged part of the archive with the
  98. command:
  99.  
  100.      zoo l@34 damaged
  101.  
  102. The result is:
  103.  
  104. Archive damaged.zoo:
  105. Zoo:  Starting at 34
  106. Length    CF  Size Now  Date      Time
  107. --------  --- --------  --------- --------
  108.      146   5%      139  31 Jan 87 18:55:14  /xyz/usr/dhesi/saying.first*
  109.      161  14%      138  31 Jan 87 18:54:36  /xyz/usr/dhesi/saying.second*
  110.       88   5%       84  31 Jan 87 18:51:26  ...
  111.      146  13%      127  31 Jan 87 18:52:12  Another.file.with.a.long.name
  112.      551  30%      384  31 Jan 87 18:55:46  adage.3
  113.       81   2%       79  31 Jan 87 18:56:50  adage.4
  114. --------  --- --------  --------- --------
  115.     1173  19%      951     6 files
  116. *: directory entry may be corrupted.
  117.  
  118. Let's explore at a different point in the archive with the command:
  119.  
  120.      zoo l@672 damaged
  121.  
  122. The result is:
  123.  
  124.     Archive damaged.zoo:
  125.     Zoo:  Starting at 672
  126.     Length    CF  Size Now  Date      Time
  127.     --------  --- --------  --------- --------
  128.          146  13%      127  31 Jan 87 18:52:12  Another.file.with.a.long.name
  129.          551  30%      384  31 Jan 87 18:55:46  adage.3
  130.           81   2%       79  31 Jan 87 18:56:50  adage.4
  131.     --------  --- --------  --------- --------
  132.          778  24%      590     3 files
  133.  
  134. Things look hopeful!  The last three directory entries seem to be intact,
  135. and if we are lucky, the first three files might also be recoverable.  To
  136. extract the recoverable data, we try the command:
  137.  
  138.      zoo x@34 damaged
  139.  
  140. and we see:
  141.  
  142.      Zoo:  Starting at 34
  143.      Zoo:  saying.fir   -- extracted
  144.      Zoo:  saying.sec   -- extracted
  145.      Zoo:  ksjdiejl.dnf -- extracted
  146.      Zoo:  Another_.nam -- extracted
  147.      Zoo:  adage.3      -- extracted
  148.      Zoo:  adage.4      -- extracted
  149.  
  150. Since no CRC error occurred during extraction, we may assume that all ar-
  151. chived files were recovered undamaged.  We were lucky:  none of the damage
  152. was in the file data.
  153.  
  154.  
  155.                                    NOTES
  156.  
  157. In a badly-damaged archive, Fiz may recognize a directory entry but the file
  158. data associated with that directory entry may be corrupted.  If Zoo reports
  159. a CRC error when extracting a file, do not use that file, since it is
  160. corrupted.  On rare occasions, if a file is badly corrupted, it may send Zoo
  161. into an infinite loop when extraction is attempted.  In such cases you
  162. should skip that directory entry and try again with the next directory entry
  163. that was listed by Fiz.
  164.  
  165. If Fiz lists a directory entry in which the filename appears to be garbage,
  166. it is still worthwhile trying to extract that file.  Zoo 1.40 and later, if
  167. correctly implemented, will correct the filename syntax to make it accepta-
  168. ble to the host system.  If the only damage was to the name of the file, the
  169. file data will still be extractable.
  170.  
  171. Fiz never changes the archive that it acts on.
  172.  
  173.  
  174.                                        -- Rahul Dhesi 1987/02/07
  175.