[lug] cpio

Robert racsw at frontiernet.net
Mon Apr 7 18:08:54 MDT 2003


On Mon, 2003-04-07 at 19:19, Peter Hutnick wrote:
> Robert said:
> > Hi folks,
> >    I'm building a backup script using cpio as the archiver.
> > One part of the script backs up selected files to a common archive file..
> > I'm using this syntax:
> >
> > find -name $TARGET -print | cpio -oAO $ARCHIVE_FILE
> >
> > I thought the syntax was correct, but apparently not, as I receive this
> > error"
> >
> > "cpio: premature end of file"
> 
> Are you sure that your find is finding anything . . . ?
> 
> And who's idea was it to give cpio an -0 and a -O switch?

That's an O as in Oscar, and it is in several documents, including one
from publib16.boulder.ibm.com and the Linux Command Reference, as well
as a published script using this same format.
  I have found several references to this problem when extracting using
cpio, but none when archiving.
....and yes, find is finding the file.

Cheers,
-- 
Robert <racsw at frontiernet.net>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 232 bytes
Desc: This is a digitally signed message part
URL: <http://lists.lug.boulder.co.us/pipermail/lug/attachments/20030407/c8481cf4/attachment.pgp>


More information about the LUG mailing list