Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!samsung!uakari.primate.wisc.edu!crdgw1!ge-dab.ge.com!tarpit!bilver!bill From: bill@bilver.uucp (Bill Vermillion) Newsgroups: comp.unix.sysv386 Subject: Re: Trouble with 'tar', tape archiver. Keywords: cpio, tar Message-ID: <1991Jan20.055312.255@bilver.uucp> Date: 20 Jan 91 05:53:12 GMT References: <1991Jan19.040951.2883@NCoast.ORG-> <1991Jan19.212640.18364@portia.Stanford.EDU> Distribution: usa Organization: W. J. Vermillion - Winter Park, FL Lines: 66 In article <1991Jan19.212640.18364@portia.Stanford.EDU-> fangchin@elaine43.stanford.edu (Chin Fang) writes: ->In article <1991Jan19.040951.2883@NCoast.ORG> ramsey@NCoast.ORG (Cedric Ramsey) writes: ->>Hello. I am running ESIX a unix sys V compatible os. I've been ->>trying to backup a directory, /mnt/code, using tar. I want to ->>do the backups to floppy disk. I used the following command: ->>$tar cevfk /dev/rdsk/f0q15d 1200 /mnt/code ->>This will backup all files an subdirectories but when I get close ->>to the last file I get 'tar read tape error'. Also, the tar does ->>prompt me to put in the floppies when needed. and the directory ->>/mnt/code has sub directories too. Can anybody help me? ->> ->I think for backing up to and from floppies, you are better off with the cpio ->utility because it senses backup media boundary (ie. when the reading or ->writing is reaching the end of the media, it will info you so and prompt you ->for new floppy). As far as I know, not every tar does this. ESIX's? I think ->the answer is no too. Xenix' tar will do but that's an exception? But the answer is yes. I just tried it now, since you said you didn't think it did it. Syntax is a snap. If you are using 1.2 meg 5.25" in drive 0 cd to the directory hierachy you wish to save and type tar cv2 . The 2 is the number of the proper drive type in the /etc/default/tar file. It knows how long the disk is, and it's blocking factor. That's one of the nice features from the Xenix side, a default tar file so you never get the k and b swapped, you always specify the proper device, it flags between non-seeking and seeking. If I didn't do tar cv2 . it would be tar cvfkbn /dev/ 1200 20 . I think tar cv2 . is better bill -> ->The syntax: -> ->from hard disk to floppy: -> ->cd to the directory you want to backup; -> ->find . -depth -print |cpio -ocavmB > /dev/rdsk/f0t (1.2 Meg) or f1t (1.4 Meg) -> ->or if no subdirectory; -> ->ls * (assuming you want everything) |cpio -ocavmB > ... (same as above) -> ->from floppies to a directory on hard disk: -> ->assuming you use 1.2 Meg drive and 5.25" floppies, -> ->cd to the appropriate directory (I can't tell you where, you set up your ->file tree) -> ->cpio -icvmB < /dev/rdsk/f0t -> ->You don't need f0q15dt or others, ESIX's floppy devices files are generally ->slightly faster (not necessary more solid, so always DOUBLE CHECK your ->backup-ed floppies to make sure there are no errors before you erase your ->originals on the hard disk!!!!!) -- Bill Vermillion - UUCP: uunet!tarpit!bilver!bill : bill@bilver.UUCP