Appending a CPIO to an existing archive


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Appending a CPIO to an existing archive
# 1  
Old 10-28-2011
Appending to an existing CPIO archive

I created a CPIO archive I wanted to add addition data to it but am having issues:

Code:
-rw-r--r-- 1 test test 629295104 2011-10-28 12:41 /home/test/Downloads/test.cpio

I tried:

Code:
sudo find /tmp -depth | cpio -oAO /home/test/Downloads/test.cpio
cpio: premature end of file

and

Code:
sudo find /tmp -depth | cpio -oAF /home/test/Downloads/test.cpio
cpio: premature end of file

Any ideas ??

Last edited by metallica1973; 10-28-2011 at 11:29 PM..
# 2  
Old 11-01-2011
Not exactly what I want but inspirational and untested

Code:
'cat cpio1 cpio2 > | gzip > cpio_all'

Will test a return the results
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Cpio - input files (from list) are stored in different order inside cpio archive - why?

Due to budget constraints I have to reinvent an Enterprise backup system in a SPARC (sun4v) Solaris estate (10 & 11). (yep - reinvent wheel, fun but time consuming. Is this wise?! :confused: ) For each filesystem of interest, to try to capture a 'catalog' at the front of each cpio archive (for... (1 Reply)
Discussion started by: am115998
1 Replies

2. Shell Programming and Scripting

Script to archive logs and sftp to another archive server

Requirement: Under fuse application we have placeholders called containers; Every container has their logs under: <container1>/data/log/fuse.log <container1>/data/log/fuse.log.1 <container1>/data/log/fuse.log.XX <container2>/data/log/fuse.log... (6 Replies)
Discussion started by: Arjun Goswami
6 Replies

3. UNIX for Dummies Questions & Answers

Cpio archive help

Hi I'm new to the forum and looking for some help with cpio archive creation. I have a bunch of directories that I need to make into a cpio archive. The problem I'm having is that when I input the commands I get the cpio archive but it creates a duplicate of the archive inside the archive... (4 Replies)
Discussion started by: reeves1985
4 Replies

4. Shell Programming and Scripting

Appending new column to existing files

Hi, i want to add another column to existing files containing strings and need to have the final output as a csv file. i have quite a number of files, each with varying number of rows and i need to append the string "test" for all the valid rows for each file. my sample raw files looks like this... (8 Replies)
Discussion started by: ida1215
8 Replies

5. UNIX for Dummies Questions & Answers

Appending lines from an existing list to each line in another existing list

Evening all ! I would like to ask your expertise on how to accomplish the following ; I have 2 lists, and would like each line from list2 to be appended to each line in list1, resulting in list3 ; List1; alpha beta charlie List2; one two three (4 Replies)
Discussion started by: TAPE
4 Replies

6. UNIX for Advanced & Expert Users

how to put a .gz file in already existing archive folder

Hi.. I have a folder within which I have two files : abc.gz and xyz.tar.gz Actualy abc was a 8 GB File and while zipping other files in xyz.tar.gz it could not be zipped due to its large size.. I have zipped abc using -E option of tar. Can someone help to put abc.gz in xyz.tar.gz..... (1 Reply)
Discussion started by: kanus
1 Replies

7. UNIX for Dummies Questions & Answers

Unable to restore cpio archive to a directory

Hello Every one, I want to back up all passwd files to /xyz/passfiles.cpio and Then restore them to /abc directory. Here is what I wrote: find / -name passwd | cpio -oc > /tmp/passwd.cpio and to restore cd abc cpio -ium < /tmp/passwd.cpio I can not find the files restored to /abc... (2 Replies)
Discussion started by: drdigital_m
2 Replies

8. Shell Programming and Scripting

insert pipes for existing and non-existing records

I have a source file like this, L4058S462 34329094 F51010141TK1070000483L4058S462 34329094 0232384840 381892 182 5690 L4058S462 34329094 F51020141FIRST CLEARING, LLC A/C 3432-9094 L4058S462 34329094 F51030141JOHAN HOLMQVIST ... (1 Reply)
Discussion started by: saravanamr
1 Replies

9. UNIX for Dummies Questions & Answers

Selective restore from a cpio tape archive

Hi, I use following command to restore data from my cpio tape archive: $cpio -icvd < /dev/rct0 But this'll restore all tape contents to the current path, what if I want only selected files from the tape, suppose I want /home/compdir/home2/Rev83/data/PL/01/*.* files to be restored... (8 Replies)
Discussion started by: tayyabq8
8 Replies

10. UNIX for Dummies Questions & Answers

help on appending data to existing data

I need to know how to record the hostname, date/time and all of the process and send it all to one file. I know that the commands I need are hostname, date and ps but I don't know how to do them all and send them all to the same file. Please help! (1 Reply)
Discussion started by: precious51980
1 Replies
Login or Register to Ask a Question