bug-tar
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-tar] GNU tar 1.22 creating USTAR not readable by other TAR implemen


From: Kent Boortz
Subject: [Bug-tar] GNU tar 1.22 creating USTAR not readable by other TAR implementations
Date: Wed, 16 Dec 2009 23:45:10 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (darwin)

Hi,

I have found that if creating a USTAR archive using

  gtar --format=ustar -cf ....

the resulting archive might not unpack correctly using some other TAR
implementations, those I have tried that failed are

  AIX 5.3
  HP-UX 11.11, 11.23, 11.31
  Solaris 8, 9, 10, 11
  SCO OpenServer 6

I tried the small snippet below. The created TAR files were
distributed to the AIX, HP-UX and other hosts, and I unpacked it there
with the TAR that came with that operating system.

If I packed with GNU TAR 1.22 they could not unpack it correctly (only
the top directory was created), if packed with Solaris TAR all could
unpack it, even GNU TAR.

  # I try be as nice as I can, 98 + 20 + 77 should be within USTAR
  # format limits even if one or two chars are wasted on '\0' or the
  # '/' delimiter
  
a=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
  b=bbbbbbbbbbbbbbbbbbbb
  
c=ccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc

  rm -fr $a
  mkdir -p $a/$b
  touch $a/$b/$c

  # GNU TAR
  gtar --format=ustar -cf gnu.tar $a
  # Solaris TAR
  /usr/bin/tar -cf solaris.tar $a

Do I do something wrong, or is this a bug in GNU tar?

If a bug, is this corrected in some later version of GNU TAR?

If just different interpretations of the USTAR standard, is there some
magic environment variable to set to get GNU tar to create archives
fully compatible with the other TAR implementations mentioned above?

kent

-- 
Kent Boortz, Senior Production Engineer
Sun Microsystems Inc., the MySQL team
Office: +46 863 11 363
Mobile: +46 70 279 11 71




reply via email to

[Prev in Thread] Current Thread [Next in Thread]