Snow leopard tarball-uploading issues

Here's the scenario:

  1. Create a tarball on your Mac (of a .git repo in my case) [ex, $tar czf repo.tgz repo.git]
  2. scp that up to your server running Linux [ex, $scp repo.tgz user@server.com]
  3. extract the tarball on your server [ex, $tar xzf repo.tgz

And you're barraged with a bunch of the following:

tar: Ignoring unknown extended header keyword `SCHILY.dev'
tar: Ignoring unknown extended header keyword `SCHILY.ino'
tar: Ignoring unknown extended header keyword `SCHILY.nlink'

The problem is that Linux uses GNU Tar, and Snow Leopard uses BSD Tar (used to use GNU Tar, which is why it used to work). The solution is to use GNU Tar on your Mac instead, ala the following command:

$cd /usr/bin; sudo ln -fs gnutar tar

To set it back you can run $cd /usr/bin; sudo ln -fs bsdtar tar .
See the later comments at http://macitbetter.com/node/354 for a lo-down.

1 Comments

I've also found that you can

I've also found that you can install homebrew and download the gnu-tar package from that and it works without having to mess with the system tar. All you have to do is create an alias or make sure that /usr/local/bin appears in your path before /usr/bin.