Amanda-Users

Re: testing a patched tar question.

2007-04-09 11:44:12
Subject: Re: testing a patched tar question.
From: Jon LaBadie <jon AT jgcomp DOT com>
To: amanda-hackers AT amanda DOT org, amanda-users AT amanda DOT org
Date: Mon, 9 Apr 2007 11:26:17 -0400
On Sun, Apr 08, 2007 at 09:43:13PM -0500, dustin AT zmanda DOT com wrote:
> On Sun, Apr 08, 2007 at 08:29:53PM -0500, Marc Mengel wrote:
> > Couldn't someone hack up a utility to do a major number swapout in the
> > file where tar keeps track of what is in the last incremental/full/etc.?
> 
> That's what I suggested in 
> 
>   http://tech.groups.yahoo.com/group/amanda-users/message/62562
> 
> I'm a little busy to work on it at the moment, if you're interested in
> taking up the task!
> 
> Dustin


Not a show stopper, but if someone does take up the task it will be important
to consider various OS's and tar versions so as to avoid linux-specific type
assumptions.  As an example, here are two gnutar-lists from different OS's
and "I think" different tar releases:

        834 589377 ./jon/.gconf/desktop/gnome/accessibility

        7602561 33040 ./jon/.gconf/apps/epiphany

In each case the second column is the inode number.  I'm guessing that the
first column is somehow identifying the device, despite their wildly different
format/sizes.  It is the same for each entry in the file, though they could
vary if "include's" in the DLE definition could pull in things from multiple
file systems.

If the current, new device value that tar will use is not known, it could be
obtained with something like this:

        cd <head of DLE>
        mkdir -p _foo/foo
        tar -cf /dev/null --listed-incremental=_bar _foo
        awk 'NR=2 {print $1}' _bar
        rm -r _foo _bar
        cd -

Assumes you can write to <head of DLE> and nothing there is named _foo nor _bar.

-- 
Jon H. LaBadie                  jon AT jgcomp DOT com
 JG Computing
 4455 Province Line Road        (609) 252-0159
 Princeton, NJ  08540-4322      (609) 683-7220 (fax)