home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 36 Tips / 36-Tips.zip / zipback.txt < prev    next >
Text File  |  1996-09-23  |  13KB  |  322 lines

  1. These are the steps I followed in backing up my 400 meg OS/2 boot
  2. drive onto two 100 meg disks in a parallel port Iomega Zip drive,
  3. with the solid InfoZip compression program.  This assumes you
  4. already have a parallel port Iomega Zip drive operating in OS/2.
  5. The drivers for OS/2 are available at Hobbes
  6. <ftp://ftp-os2.nmsu.edu/os2/drivers> and on Pete Norloff's OS2 BBS
  7. <http://www.os2bbs.com>.  I think I might have gotten them from
  8. Compuserve.  Mine is a FAT system, so if you're using an HPFS
  9. system you'll have to look into how that affects things.  I'm not
  10. sure it does, since the centerpiece here is the Info zip utility
  11. (v. 2.0.1, file date 9-19-93), which preserves EA's inside zip
  12. files which don't themselves have EA's.  Therefore I don't think
  13. you have to worry about doing a format of the Zip disk to HPFS.
  14. Zip and unzip are available at lots of places.  Typing "zip" and
  15. "unzip" at the commmand line tells you their switches.  I haven't
  16. yet gotten around to looking at the newer versions that were
  17. published this year.
  18.  
  19. Here goes:
  20.  
  21. 1.   Make OS/2 utility (boot) diskettes.  I did this by
  22.      starting with the "Create Utility Diskettes" icon under
  23.      the "System Setup" icon in "OS/2 System."  Add to the
  24.      CONFIG.SYS file on the #2 disk [officially called DISK 1]
  25.      the line "DEVICE=A:\OAD\OS2.SYS" (no quotes).  I also
  26.      added:
  27.        libpath=.;\;a:\;
  28.  
  29.      and changed the set path and dpath to:
  30.  
  31.        set path=\;a:\;
  32.        set dpath=\;a:\;
  33.  
  34.      I'm not sure what if any of that was necessary since my main
  35.      problem in getting the Zip drive to work turned out to be
  36.      trying to put the drivers in A:\ rather than in A:\OAD.  But
  37.      those config.sys lines are as above now, and they work.
  38.  
  39.      In the course of experimenting to make things work I also
  40.      added three other DLL files.  See the complete directory
  41.      listing for my customized OS/2 Utility Diskette #2 below.  One
  42.      or another of the added DLL's may or may not be necessary.  I
  43.      think I also added TEDIT and TEDIT.HLP
  44.  
  45.      And of course you need to copy ZIP.EXE and UNZIP.EXE to that
  46.      disk.
  47.  
  48. 2.   ZIP driver.  Make a directory named OAD on Utility Diskette
  49.      #2--the one with CMD.EXE and CONFIG.SYS on it.  Don't bother
  50.      trying any other directory name.  There isn't room to get all
  51.      of your OAD files onto the floppy disk with all the DLL files
  52.      that are already there.  Use a file viewer such as LIST or
  53.      HYPERVIEW to look in the customized files CONFIG.OAD,
  54.      GENOAD.MAP, and CONFIG.MAP in your hard drive OAD directory to
  55.      help you guess which files might be necessary with your
  56.      machine to make the boot disk work the Zip drive, and copy
  57.      files to A:\OAD accordingly.  The ones I ended up with are
  58.      shown in the complete directory listing for my customized OS/2
  59.      Utility Diskette #2, below.  I did not end up having to rerun
  60.      GENOAD, so GENOAD.EXE is definitely not necessary even though
  61.      it's on there.  Obviously you're going to have to experiment
  62.      with booting with these utility disks to make sure you can
  63.      access your Zip drive when you use these boot diskettes.
  64.  
  65. 3.   Directory listing.  You need a file with a plain list of all
  66.      the directories in your root directory looking like this:
  67. --------cut---
  68. C:\OS2
  69. C:\OS2_MOU
  70. C:\CMD
  71. C:\WP51
  72. -------cut------
  73.  
  74. Here's how I did it:
  75.      With the #2 utility disk [officially DISK 1] in drive A, run
  76.      the command:
  77.           dir c:\*.* /o:g /a > a:\zipback.lst
  78.  
  79.      [If your OS/2 drive is some drive other than c: then
  80.      substitute that letter in place of c: in the command.]
  81.  
  82.      Edit a:\zipback.lst as follows:
  83.           a.   Delete all lines that aren't directory names.  That
  84.                includes headings and all names of root directory
  85.                files.
  86.           b.   If there are any directory names with extensions,
  87.                close up the spaces and insert the ".".  Example:
  88.                "SIO  153" becomes "SIO.153"
  89.           c:   Delete everything after the directory name on each
  90.                line.  (I used a word processor macro that searched
  91.                for a space, deleted the remainder of the line,
  92.                moved to the beginning of the next line and
  93.                repeated until there were no more spaces in the
  94.                file.)
  95.           d:   Add c:\ [or whatever drive] at the beginning of
  96.                every line.  (I used a word processor search and
  97.                replace function to replace <return> with
  98.                <return>C:\)
  99.  
  100. 4.   Make a conservative guess as to which of your directories with
  101.      their files and subdirectories will fit, zipped with the files
  102.      in your root directory, on one Zip disk.  Move part of your
  103.      directory list from a:\zipback.lst to a:\zipback1.lst
  104.      according to your guess.  If you underestimate what will fit
  105.      there's no problem.  You can add to it.  If you overestimate
  106.      what will fit on the disk when you run zip I don't know what
  107.      happens.  I didn't do that.
  108.  
  109. 5.   Make three batch (.cmd) files on the #2 (DISK 1) Utility disk.
  110.      Each has just one line, so IGNORE ANY WRAP here, and put
  111.      everything on one line with a space where the wrap occurred,
  112.      for each of the three.  Again, if you're doing a drive other
  113.      than c:, substitute.
  114.  
  115. ZIPC.CMD
  116. --------------cut----
  117. a:\zip.exe -u -g -S drive-c1.zip c:\*.* -x c:\swapper.dat
  118. c:\ea?data.?sf
  119. --------------cut----
  120.  
  121. ZIPBACK1.CMD
  122. --------------cut----
  123. type a:\zipback1.lst | a:\zip.exe -u -g -r -S -@ drive-c1.zip -x
  124. c:\os2\system\swapper.dat
  125. --------------cut----
  126.  
  127. ZIPBACK2.CMD
  128. --------------cut----
  129. type a:\zipback2.lst | a:\zip.exe -u -g -r -S -@ drive-c2.zip -x
  130. c:\os2\system\swapper.dat
  131. --------------cut----
  132.  
  133. Here's the complete directory listing of what I ended up with on
  134. the #2 Utility Diskette.  [There's a heretofore unmentioned file,
  135. ZIPBACK2.LST, which we'll get to.]:
  136.  
  137. The volume label in drive A is DISK 1.
  138. The Volume Serial Number is E33F:B815.
  139.  
  140. Directory of A:\
  141.  
  142. ANSICALL DLL       512   9-23-94  3:31a
  143. BKSCALLS DLL       512   9-23-94  3:32a
  144. BMSCALLS DLL       512   9-23-94  3:34a
  145. BVHINIT  DLL      7999  10-09-94  7:03p
  146. BVSCALLS DLL       512   9-23-94  3:30a
  147. CLOCK01  SYS      3735   9-23-94  4:17a
  148. CLOCK02  SYS      3834   9-23-94  4:17a
  149. CMD      EXE     91648   9-23-94  4:55a
  150. CONFIG   SYS       510   9-20-96  8:32p
  151. COUNTRY  SYS     25610   9-23-94  4:53a
  152. DOSCALL1 DLL    137084  10-07-94 12:52p
  153. EA DATA   SF      9216   9-19-96  6:24p
  154. HARDERR  EXE     14888  10-07-94 12:47p
  155. HPFS     IFS    135746   9-23-94  4:38a
  156. IBM1FLPY ADD     30994  10-05-94 10:31p
  157. IBM1S506 ADD     27104  10-06-94 10:41p
  158. IBM2ADSK ADD      9798  10-05-94 10:32p
  159. IBM2FLPY ADD     13718  10-05-94 10:31p
  160. IBM2SCSI ADD     32373  10-03-94  1:39p
  161. IBMINT13 I13      9860  10-05-94 10:32p
  162. IBMKBD   SYS      5548  10-03-94  2:21p
  163. KBDBASE  SYS     27989  10-03-94  2:23p
  164. KBDCALLS DLL      1024   9-23-94  3:07a
  165. KEYBOARD DCP    137500   9-23-94  4:48a
  166. MOUCALLS DLL      1024   9-23-94  3:35a
  167. MSG      DLL       512   9-23-94  3:17a
  168. NAMPIPES DLL      1024   9-23-94  3:34a
  169. NLS      DLL       512   9-23-94  3:16a
  170. NPXEMLTR DLL     25504   9-23-94  5:07a
  171. OAD          <DIR>       9-20-96  6:53p
  172. OS2CHAR  DLL       512   9-23-94  3:26a
  173. OS2DASD  DMD     33562  10-05-94 10:30p
  174. OS2LOGO          19358  10-05-94 11:05p
  175. PRINT01  SYS     10910  10-03-94  2:38p
  176. PRINT02  SYS     10022  10-03-94  2:38p
  177. QUECALLS DLL      1024   9-23-94  3:19a
  178. RESOURCE SYS     27084  10-05-94 10:29p
  179. SCREEN01 SYS      9461  10-08-94  7:14p
  180. SCREEN02 SYS      9393  10-08-94  7:14p
  181. SESMGR   DLL      1536  10-07-94 12:54a
  182. SIPANEL1 DLL     31312  10-08-94  1:07a
  183. SYSINST1 EXE      4960  10-25-94  4:06p
  184. TEDIT    HLP     14596   9-01-94  6:52p
  185. TEDIT    EXE     10820   9-23-94  5:21a
  186. UNZIP    EXE     95795   8-29-94 11:40a
  187. VIOCALLS DLL      2048   9-23-94  3:28a
  188. VTBL850  DCP     10478   9-23-94  4:15a
  189. ZIP      EXE     93232   9-19-93  1:04p
  190. ZIPBACK  LST         1   9-21-96  9:15a
  191. ZIPBACK1 CMD        92   9-22-96  2:39p
  192. ZIPBACK1 LST       670   9-21-96  9:15a
  193. ZIPBACK2 LST       322   9-21-96  1:54a
  194. ZIPBACK2 CMD        92   9-22-96  2:39p
  195. ZIPC     CMD        74   9-20-96 10:48p
  196.       54 file(s)    1144156 bytes used
  197.  
  198. Directory of A:\OAD
  199.  
  200. .            <DIR>       9-20-96  6:53p
  201. ..           <DIR>       9-20-96  6:53p
  202. CONFIG   OAD       369   2-25-96 10:24p
  203. CONFIG   MAP       199   2-25-96 10:15p
  204. CONFIG   DEV      3765  10-10-95  2:34a
  205. GENOAD   MSG      8828  10-10-95  2:34a
  206. GENOAD   HLP     15670  10-10-95  2:34a
  207. GENOAD   EXE    138101  10-10-95  2:34a
  208. IOM$ERR  DAT      3119  10-10-95  2:34a
  209. IOM$MSG  DAT     12416  10-10-95  2:34a
  210. NULLADP  OPT       335  10-10-95  2:34a
  211. NULLADP  ADP      1096  10-10-95  2:34a
  212. NULLDEV  OPT       286  10-10-95  2:34a
  213. NULLDEV  DEV     15489  10-10-95  2:34a
  214. OS2      SYS     10878  10-10-95  2:34a
  215. PPA      OPT       499  10-10-95  2:34a
  216. PPA      ADP      3146  10-10-95  2:34a
  217. PPA3     OPT       569  10-10-95  2:34a
  218. PPA3     ADP     10777  10-10-95  2:34a
  219. ZIP-100  OPT       436  10-10-95  2:34a
  220. ZIP-100  DEV     15489  10-10-95  2:34a
  221.       21 file(s)     241467 bytes used
  222. Total files listed:
  223.       75 file(s)    1385623 bytes used
  224.                       54272 bytes free
  225.  
  226. 6.  Dual boot to DOS.
  227.  
  228. 7.  Reboot with the diskettes.
  229.  
  230. 8.  Make the Zip drive the current drive.  [In other words, if it's
  231. drive E, get an [E:\] prompt.
  232.  
  233. 9.  Run ZIPC.  This starts the file DRIVE-C1.ZIP on your Zip disk
  234. with just the files from your root directory.
  235.  
  236. 10. Run ZIPBACK1.  This will add to DRIVE-C1.ZIP the directories
  237. listed in A:\ZIPBACK1.LST, with their files and subdirectories.
  238.  
  239. 11. If you've got lots of room left on the first Zip disk, rename
  240. A:\ZIPBACK1.LST to something else, move some more directory names
  241. from A:\ZIPBACK.LST to a new A:\ZIPBACK1.LST, go back to the Zip
  242. drive ([E:\] prompt) and rerun ZIPBACK1.  Repeat until you've got
  243. the first 100 meg disk as full as you want to try to get it.  [You
  244. might want to recombine the files listing the directories you've
  245. backed up so far into A:\ZIPBACK1.LST.]
  246.  
  247. 12.  Repeat steps 4, 10, and 11 with a fresh Zip disk, using
  248. ZIPBACK2.LST and ZIPBACK2.CMD in place of ZIPBACK1.LST and
  249. ZIPBACK1.CMD.  This did it for me.  Obviously you can go on to more
  250. disks if you need to.
  251.  
  252. 13.  If you like you can verify the integrity of your zip file
  253. with:
  254.  
  255. zip -T drive-c1.zip
  256.  
  257. Note that case is important with all the zip switches.
  258.  
  259. You can also list the contents of the zip file with:
  260.  
  261. unzip -l drive-c1.zip
  262.  
  263. If you want to see the filenames in a file, use:
  264.  
  265. unzip -l drive-c1.zip > c:\filelist
  266.  
  267. 14.  I have not, and don't plan to restore my whole zip file as a
  268. test.  I have, however, done restoration of a file and a directory.
  269. You can do it like this (for example):
  270.  
  271. a. Make a directory \TESTBACK on a drive with 25 megs or so of
  272. space.  I'm going to assume it's drive c:
  273.  
  274. b. Insert the Zip disk on which you backed up the directory you
  275. want to test.  I'm going to use the \TCPIP directory as an example
  276. and assume it was in your ZIPBACK1.LST.  Change to the Zip drive as
  277. the current drive.  Do:
  278.  
  279. unzip drive-c1.zip tcpip/*.* -d c:\testback
  280.  
  281. Note the direction of the slash in "tcpip/*.*" and note there's
  282. nothing in front of the name.  Those are important.
  283.  
  284. If you want to see that the ea's are really there on your FAT
  285. system you can do, in c:\testback\tcpip:
  286.  
  287. dir /n
  288.  
  289. I leave it to you to get rid of c:\testback and all its
  290. subdirectories.  Remember it has to be an OS/2 method to deal with
  291. the EA's.  You might take a look at OS2-Commander.
  292.  
  293. 15.  If you ever do need a complete restore, the first thing you'll
  294. want to do is install the same version of DOS that you're running.
  295. I think you should know where your original DOS disks are, and have
  296. diskcopies of them.  Use either format c: /b or sys c: to put the
  297. DOS system files in the right spot on the hard drive.  Then, boot
  298. with your OS2 utility disks and restore your zip files.  The
  299. procedure for that is of course:
  300.  
  301. a. Get the [E:\] prompt [whatever the Zip drive is];
  302. b. unzip *.zip -d c:\ [or whatever your OS/2 drive is].
  303.  
  304. Remember to SAY NO to overwriting the two DOS system files.  The
  305. names vary.  There's IO.SYS with MSDOS.SYS, and IBMDOS.COM with
  306. IBMBIO.COM.  After everything's restored you'll be in DOS mode, as
  307. you were for this backup.  Dual boot back to OS/2.
  308.  
  309. Well that's all folks.  If I've left something essential as well as
  310. a lot of basics, let me know.  The lines of the .CMD files above
  311. are imported from the working files, so I don't think there's any
  312. mistake there.  I'll answer mail, but I don't promise to solve any
  313. problems.
  314.  
  315. Credit to Duane Chamblee for the example of using zip with a
  316. directory list and the -@ switch, contained in ZIPINS.ZIP at the
  317. OS2 BBS <http://www.os2bbs.com>.
  318.  
  319. Larry Scott
  320. scott@buffnet.net
  321. copyright 1996--distribute freely but give me credit, please
  322.