The FTimes Project The HashDig Project The WebJob Project The PaD Project
Location: / Home / FTimes / Man Pages / tarmap
Man Pages
FTimes
Home

NAME

TarMap - Map the contents of a tar archive

SYNOPSIS

tarmap {-m|--map} {-f|--file} file|-

tarmap {-v|--version}

Note: Command line arguments are position dependent, and argument snuggling (e.g., '-mf') is not supported. All arguments and their values (if any) must be separated by whitespace.

DESCRIPTION

TarMap is a utility for mapping the files in a tar archive without having to unpack and write them to disk first. The output produced by this utility is roughly equivalent to FTimes output produced with the following FieldMask:

    none+size+md5+sha1

MODES OF OPERATION

The modes of operation described in this section are mutually exclusive. In other words, only one mode may be specified per invocation.

{-m|--map} {-f|--file} file|-

Map the contents of the specified file.

{-v|--version}

Display version information and exit.

RETURN VALUES

Upon successful completion, a value of 0 (XER_OK) is returned. Otherwise, one of the following error codes is returned:

  • 1 = XER_Usage

  • 2 = XER_BootStrap

  • 3 = XER_ProcessArguments

  • 4 = XER_WorkHorse

  • 5 = XER_RunMode

EXAMPLES

Example 1. Map the contents of a normal tar ball

This example demonstrates how to map the contents of a normal tar ball called test.tar.

    tarmap -m -f test.tar

Example 2. Map the contents of a compress'd tar ball

This example demonstrates how to map the contents of a compress'd tar ball called test.tar.Z.

    uncompress -c test.tar.Z | tarmap -m -f -

Example 3. Map the contents of a gzip'd tar ball

This example demonstrates how to map the contents of a gzip'd tar ball called test.tar.gz.

    gunzip -c test.tar.gz | tarmap -m -f -

Example 4. Map the contents of a bzip2'd tar ball

This example demonstrates how to map the contents of a bzip2'd tar ball called test.tar.bz2.

    bunzip -c test.tar.bz2 | tarmap -m -f -

Example 5. Compare the contents of two tar balls

This example demonstrates how to use tarmap and ftimes to compare the contents of two tar balls called test.old.tgz and test.new.tgz.

    gunzip -c test.old.tgz | tarmap -m -f - > test.old.map
    gunzip -c test.new.tgz | tarmap -m -f - > test.new.map
    ftimes --compare all test.old.map test.new.map

SEE ALSO

bunzip2(1), ftimes(1), gunzip(1), uncompress(1)

AUTHOR

Klayton Monroe

HISTORY

This utility was initially written to help determine if any files on a system with no prior baseline had been changed. While the system in question didn't have a baseline, it did have several tar ball backups. The main issue was that the backups were so large that extracting them to temporary storage first would have been impractical. This utility, allowed us to avoid that issue by directly processing an uncompressed stream of the backup (e.g., via gunzip or bunzip2).

This utility first appeared in FTimes 3.8.0.

Copyright 2000-2019 The FTimes Project, All Rights Reserved.
The FreeBSD Project SourceForge Logo KoreLogic, Inc.