tar in RH Linux - probable stupid user error

tar in RH Linux - probable stupid user error

Post by <no.. » Thu, 16 Aug 2001 17:16:03



     Okay, this is pretty srupid.  I received a tar file from a client.
When I  try to extract it I get the following error message:

"This does not look like a tar archive"

I'm using tar -xf oldfile.tar.gz, in RedHat 7.

What makes this more exciting is that someone also downloaded a copy and
they had no trouble extracting the file.  I suspect that this is
something simple (and obvious) but not to me.

Thanks in advance,

Lee

 
 
 

tar in RH Linux - probable stupid user error

Post by Eric » Thu, 16 Aug 2001 17:54:51


Quote:>      Okay, this is pretty srupid.  I received a tar file from a client.

it is a user error.

Quote:> When I  try to extract it I get the following error message:

> "This does not look like a tar archive"

because it's a gzipped tar archive

Quote:> I'm using tar -xf oldfile.tar.gz, in RedHat 7.

you should use tar zxf oldfile.tar.gz

Quote:> What makes this more exciting is that someone also downloaded a copy and
> they had no trouble extracting the file.  I suspect that this is
> something simple (and obvious) but not to me.

he probably did use the z flag.
(Or his browser already unzipped it)

Eric

 
 
 

tar in RH Linux - probable stupid user error

Post by mvja » Thu, 16 Aug 2001 23:39:12



> because it's a gzipped tar archive

> > I'm using tar -xf oldfile.tar.gz, in RedHat 7.

> you should use tar zxf oldfile.tar.gz

> > What makes this more exciting is that someone also downloaded a copy and
> > they had no trouble extracting the file.  I suspect that this is
> > something simple (and obvious) but not to me.

> he probably did use the z flag.
> (Or his browser already unzipped it)

Or maybe he wastefully issued two commands instead of your more efficient
one liner, he could have used gunzip to unzip the tar archive then tar to
extract the files...   A little wasteful perhaps, but this method might be
a little easier for some newbie to figure out what's happening ;)

$ gunzip oldfile.tar.gz
$ tar xf oldfile.tar

        ~^~   ~^~
        (*)   (*)    Joe (theWordy) Philbrook
            ^