More tar help

Jonathan I. Kamens jik at athena.mit.edu
Fri Feb 15 07:30:25 AEST 1991


In article <1991Feb14.170407.1422 at unicorn.cc.wwu.edu>, n8743196 at unicorn.cc.wwu.edu (Jeff Wandling) writes:
|> gwyn at smoke.brl.mil (Doug Gwyn) writes:
|> 
|> >In article <25945 at adm.brl.mil> P_SECINARO at unhh.unh.edu writes:
|> >>I downloaded the tar file as ASCII ...
|> 
|> >Don't do that!  "tar" files will be corrupted unless you download them
|> >in binary (image) mode.
|> 
|> Oh yea? What's the difference between foo.tar and foo.tar.Z ?

  I would like to politely suggest that you take a slightly less
confrontational tone, especially when you're contradicting Doug Gwyn about
something concerning Unix.  Because, in the vast majority of cases, when you
contradict Doug Gwyn about something concerning Unix, you're the one that's
wrong, not Doug.

  And, indeed, in this case, you're wrong.

  The difference between foo.tar and foo.tar.Z is that the latter is
compressed and the former is not.  This has almost nothing to do with the
question at hand, which is whether or not a tar archive can contain characters
that would get mucked up by an ftp ASCII-mode transfer.

  The answer to that question is yes.

  Ignoring all the things that ftp is *allowed* and *supposed* to do during an
ASCII transfer which may interfere with the transfer of binary files, I will
quote from the BUGS section of the man page for the ftp we have installed on
our machines (I believe it's from the 4.3tahoe sources, but I'm not certain):

     An error in the treatment of carriage returns in the 4.2BSD
     UNIX ascii-mode transfer code has been corrected.  This
     correction may result in incorrect transfers of binary files
     to and from 4.2BSD servers using the ascii type.  Avoid this
     problem by using the binary image type.

|> I've been able to send tar files through the net with no problem. It's
|> for the compressed files that I need to set 'bin'ary mode.

  Then you've been lucky.

|> Example:
|> 
|> tar cf - . | rsh other_host dd of=home.tar

  What does this have to do with what we are talking about?

  We're talking about using *FTP* to download files.  What does your example,
using rsh, have to do with FTP transfers?

-- 
Jonathan Kamens			              USnail:
MIT Project Athena				11 Ashford Terrace
jik at Athena.MIT.EDU				Allston, MA  02134
Office: 617-253-8085			      Home: 617-782-0710



More information about the Comp.unix.questions mailing list