On Sat, Nov 10, 2018 at 05:08:01 -0500, Gene Heskett wrote:
> But what is the correct gzip syntax to get a listing of the contents of
> one of these smaller files?
>
> All I can get out of last nights /usr/local file from the unpack by:
>
> dd if=00043.coyote._usr_local.1 bs=32k skip=1 | /bin/gzip -dcl --name
> is:
> compressed uncompressed ratio uncompressed_name
> -1 -1 0.0% stdout
>
> as if there is nothing in the file, and it should have had in this case,
> all the new sbin/am* files from the rebuilt amanda install, but that
> file for /usr/local is just short of 47 megs. So its probably all
> there, and I'm not holding my mouth right with the gzip invocation.
>
> okteta says there is data starting at the 32k offset, another 46.9 or so
> megs of it, but no names visible due to the compression. Call me
> puzzled.
The Amanda does compression by piping the entire dump-archive on-the-fly
to a gzip process, so that's why the gzip header doesn't include an
explicit file name.
You use tar for your dumps so you just need to pipe to tar at the end of
your command chain in order to see the contents of the tar archive:
dd if=00043.coyote._usr_local.1 bs=32k skip=1 | zcat | tar -tvf -
(Or, if you don't mind departing a bit from exactly reversing Amanda's
pipeline, to save a few keystrokes you can let tar invoke gzip rather
than calling it explicitly:
dd if=00043.coyote._usr_local.1 bs=32k skip=1 | tar -tzvf -
)
Nathan
----------------------------------------------------------------------------
Nathan Stratton Treadway - [email protected] - Mid-Atlantic region
Ray Ontko & Co. - Software consulting services - http://www.ontko.com/
GPG Key: http://www.ontko.com/~nathanst/gpg_key.txt ID: 1023D/ECFB6239
Key fingerprint = 6AD8 485E 20B9 5C71 231C 0C32 15F3 ADCD ECFB 6239