As
era correctly assumed, tar was initially a tool for creating and extracting tape archives, hence its name.
For instance the manpage for tar on HP-UX still mentions this
Quote:
tar(1) tar(1)
NAME
tar - tape file archiver
And for those historic kind of uses it goes on, informing that indeed the
-f option can be omitted,
where it defaults to the first non-rewinding tape device special file
Quote:
DESCRIPTION
The tar command saves and restores archives of files on a magnetic
tape, a flexible disk, or a regular file. The default archive file is
/dev/rmt/0m. See the -f option below. Its actions are controlled by
the key argument.
Of course, on Linux distros bundled with the GNU tar this does not apply
because I think that Linux wasn't targeted in the first place at users who can afford
expensive tape drives and media.
Both tools have their pros and cons.
Of course, we must not confuse the myriad of features the GNU tar offers nowadays
with those spartan tar implementations that you would find on most commercial Unices.
Historically, tar didn't back up special files.
Also you couldn't easily exclude files from being captured in the archive
as well as not restrict the recursion to filesystem boundaries.
(GNU tar today has all sorts of options that let you do this)
On the other hand it is easy to append files to existing tar archives which you can't with cpio.
Another drawback of cpio is that it usually only is useful in combination with find,
which makes two stat() syscalls for each file (albeit the second is read from the buffer cache).
One big strength of cpio draws from the abundance of filter criteria,
which on the other hand can become quite daunting to the average user.
Think of the arcane -prune logic with lots of quoting noise for parens if you want to exclude certain dirs.
But to the remedy came a tool which sadly his often hardly known.
It kind of took its name from the former rivalry of the two, tar vs. cpio.
As pax is the Latin word for peace, so it is aptly named.
pax lets you do much more than a mere tar (e.g. in situ renaming of target paths or stripping) while it maintains tar's ease of use.
pax should really be given more attention.