git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: cg-export incompatible with older versions of GNU tar

From
Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
Date
Sep 22, 2005, 19:13 UTC
Message-ID
<43330256.7000505@lsrfire.ath.cx>
In-Reply-To
<20050922124338.246D535267B@atlas.denx.de>
Wolfgang Denk wrote:
Show 12 quoted lines
> In message <20050922120841.GH21019@pasky.or.cz> you wrote:
> 
>>>-> tar jxf foo.tar.bz2 
>>>tar: pax_global_header: Unknown file type 'g', extracted as normal file
>>>...
> 
> 
>>It is unclear if the tar actually extracts the archive or not, though.
>>Does it just complain with those warnings, or are they fatal errors?
> 
> 
> In this case extraction went fine, except for the warning message.

And you get an extra file, pax_global_header, containing the commit ID of the archive's contents.

Show 7 quoted lines
> I had other error reports from customers befroe, where unpacking  the
> tarballs failed - instead of the origianl source tree just a bunch of
> *.data  and  *.paxheader  were created; error messages in these cases
> looked like this:
> 
> tar: pax_global_header: Unknown file type 'g', extracted as normal file
> tar: ea1efd7f213469bcde030e00ac9f89ed16256869.paxheader: Unknown file type 'x', extracted as normal file
[snip]

This happens when you have pathes inside the tar file that are longer than 100 characters. Is this taken from a real-world project or is it just some test?

All your files with pathes longer than 100 chars will be extracted as <SHA1>.data, with an accompanying <SHA1>.paxheader file. The latter contains the real filename. You could then repair the mess by renaming them manually or write a script that does it for you. Or you could simply update tar. :-)

Lately I noticed that the tar version used by the BSDs also doesn't understand Pax extended headers. I guess they're not that popular a feature.

> [But this was with older versions of git / cogito, so I'm not sure if
> this still applies.]
Nothing has changed in this respect, basicly since git-tar-tree went in.
René
Previous: Wolfgang Denk
Message 4 of 4 in “cg-export incompatible with older versions of GNU tar”
  1. Wolfgang DenkSep 22, 2005
  2. Petr BaudisSep 22, 2005
  3. Wolfgang DenkSep 22, 2005
  4. Rene ScharfeSep 22, 2005

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.