Path: utzoo!utgpu!news-server.csri.toronto.edu!mailrus!cs.utexas.edu!wuarchive!uunet!mcsun!hp4nl!phigate!philica!adrie From: adrie@philica.ica.philips.nl (Adrie Koolen) Newsgroups: comp.os.minix Subject: Re: Cpio vs. Tar Keywords: which is better? Message-ID: <653@philica.ica.philips.nl> Date: 27 Aug 90 11:25:35 GMT References: <2627@unccvax.uncc.edu> Reply-To: adrie@beitel.ica.philips.nl (Adrie Koolen) Organization: Philips TDS, Innovation Centre Aachen Lines: 20 In article <2627@unccvax.uncc.edu> cs00chs@unccvax.uncc.edu (charles spell) writes: >I noticed that cpio produces much larger archive files than tar. > >What would be some advantages of using cpio instead of tar? That's strange. Tar uses very inefficient and large headers. While archiving half of the command sources, tar produced a file of 627KB, but the cpio generated file was 584KB. No so much smaller, but at least not larger than the tar file! The commands, which I archived, were rather large files, so I tried to archive all the C sources in lib/other. Tar produced a file of 152KB, cpio a file of 112KB. The directory contained 58 files, most of which were under 1KB. I used `ls *.c | cpio -ocvB >lib.cpio' to generate the cpio file. When not using the `c' and the `B' options, the cpio file was only 107KB. I don't understand how you got a cpio file, that was significantly larger than the corresponding tar file. What sort of files did you archive? Adrie Koolen (adrie@ica.philips.nl) Philips Innovation Centre Aachen