working difference between tar, cpio, and pax ?

Posted on 2008-11-10
Medium Priority
Last Modified: 2013-12-27
What is the working difference between the tar,cpio and pax ? Under which circumstances we should use one over other ?
Can someone please explain me the working difference ?
Question by:beer9
LVL 40

Assisted Solution

omarfarid earned 200 total points
ID: 22921969
all are backup tools / commands that are used to backup files and directories. the difference is mostly in the way the backup is created.

LVL 22

Accepted Solution

Brian Utterback earned 400 total points
ID: 22922104
They have slightly different attributes and capabilities. The tar format is probably the most widely used. However, the portable tar format used (USTAR) has some limitations that has resulted in various extensions being made to the format, which are not always compatible across platforms. The cpio program is less used, but generally handles special files better than tar does. It can also handle larger UID numbers than tar can in a standard manner, and is more portable than tar, except that cpio may not be available at all. The pax is the most capable of all, but also the least used. It can also read and write its own native standard format as well as tar and cpio. Pax also can do some interesting conversions on the fly, like renaming the files being extracted.  

In general, you should probably stick to tar unless you have some specific issues with it. Not because it is particularly better, but because the expertise is more common.

LVL 48

Assisted Solution

Tintin earned 400 total points
ID: 22924847
If you are wanting to do system backups on a Solaris server, then ufsdump is probably your best option.

Author Comment

ID: 22940174
Got this article, basic concept got cleared. :)


Author Closing Comment

ID: 31515036

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello fellow BSD lovers, I've created a patch process for patching openjdk6 for BSD (FreeBSD specifically), although I tried to keep all BSD versions in mind when creating my patch. Welcome to OpenJDK6 on BSD First let me start with a little …
In tuning file systems on the Solaris Operating System, changing some parameters of a file system usually destroys the data on it. For instance, changing the cache segment block size in the volume of a T3 requires that you delete the existing volu…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.
Suggested Courses
Course of the Month14 days, 22 hours left to enroll

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question