I got a request from my coworker to retrieve one lost file from a backup archive. when i check the archive, it's a big file with 67 GB, and the file ended with .cpio. How could I unzip this file and retrieve a file called Freight Survey Totals.xls (the original path of the file is /u1/shares/ncshare/Freight Survey Totals.xls) Thank you a lot.
I am waiting for solution online, please help.
[root@triton DACS]# ls -l
total 65681548
-rw-rw-r-- 1 dacs dacs 67257892864 Dec 18 00:06 ncdacs2_20121217223057.cpio
drwxr-xr-x 2 root root 4096 Jan 4 13:23 tmp
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
i am running your command now, it looks like it's running there. but nothing displayed on the screen yet. I will leave it there. Hopefully, after 40 minutes, it can finish.
Ordinarily speaking, How long does it take to unzip a file from an archive of 67 G ?
Thank you , Kostasp and woolmilkporc for your timely reply. I am really appreciating your posts here. That's the reason I love EE.com.
Jason Yu
ASKER
for the above command, where is the unzipped file after running/
If you're unsure about the filename (spelling) try
cpio -ivt < archivefile.cpio
so you'll get a table of contents.
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
Once you found the file, use its full name to extract it.
The fact that it didn't work up to now could also be related to the spaces in the filename. I, personally, never have spaces in filenames (but I don't have to deal with Windows clients either).
If this is the culprit something like the following could help:
Unlimited question asking, solutions, articles and more.
woolmilkporc
4) Yes, the file is not there. Seems there is nothing from /u1/... present at all.
Seems you have some special script in place to create the archive which prepends a backslash to the spaces in filenames.
So, if the file were present, this format "*Freight*Survey*Totals.xls" should have done the trick.
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!
Walt Forbes
Jason Yu
ASKER
yes, thank you very much. Since the office in North Carolinze have to close now, I have to ask them to switch the tape out because I don't want to this archive be overwritten. I have to keep working on this next Monday.
But i really feel moved by your help. I should treat you for a dinnder for this work.
I am in Los Angeles, CA. my email is condescendent@gmail.com. Give me an email when you have time. I want to make friends with you.
Jason Yu
ASKER
From the output, it looks like all the recoverried files were written back to their original position, am I right?
woolmilkporc
No. Two things:
1) You used the -t flag, which means "table of contents". So nothing was written, you just saw the list of files contained in the archive.
2) Please note the missing leading slash. e. g. in "u4/mysql/data21/prod/FreightZones.frm"
So even if the files had been written (they haven't!) their new position would be relative to your current directory, so if you were in /tmp you would have written "/tmp/u4/mysql/data21/prod/FreightZones.frm". Got the difference? But once more, nothing has been written!
i am running your command now, it looks like it's running there. but nothing displayed on the screen yet. I will leave it there. Hopefully, after 40 minutes, it can finish.
Ordinarily speaking, How long does it take to unzip a file from an archive of 67 G ?
Thank you , Kostasp and woolmilkporc for your timely reply. I am really appreciating your posts here. That's the reason I love EE.com.