Many resources are made up by a number of filess — for example a program may be accompanied by a few necessary libraries, a license, documentation, etc. For easy transportation or storage it may be useful to bundle up this number of files into one big container file. This is the purpose of archiving software.

The process of making one such container or archive file is called archiving or packing. Reconstructing the original files from the archive is termed unarchiving or unpacking.

The most basic archivers just take a list of files and concatenates their contents sequentially into the archive. In addition the archive must also contain some information about at least the names and lengths of the originals, so that proper reconstruction is possible. Most archivers also restore any meta-information about a file that an operating system provides (like ownership, timestamps, access control).

The Unix tools ar, tar, cpio (for "archiver", "tape archiver, and "copy in/out", respectively) are examples of such a basic archiver.

Many archivers, though, incorporate lossless data compression. Since the prime motivation for archiving is better transporation and storage, this makes perfect sense. Compressed archives take less space or bandwidth and therefore make for faster and cheaper transport/storage.

Due to the many different compression algorithms used, a number of incompatible archive formats exist, including ace, arj, lha, rar, zip.

Users of basic archivers may reach a similar effect through compressing the result of packing (and uncompressing before unpacking). In fact modern tar programs includes support for calling a (de)compression program, so that it looks just as if tar itself could handle compressed archives. This approach has two advantages:

  • It follows the Unix toolbox concept that each program should accomplish a single task, but that perfectly. Once a better compressor is developed, users may use that immediately, without having to give up their archiver.
  • Since the whole archive is compressed, redundancy between archived files can be eliminated. An archiver compressing each archived file in isolation cannot exploit these inter-file redundancy.