Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-22-2005 09:25 AM
02-22-2005 09:25 AM
cpio
I want to copy into only one archive, de contents of a directory and all its subdirectories and files.
What is the sintax to do this using CPIO ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-22-2005 09:30 AM
02-22-2005 09:30 AM
Re: cpio
find . -print | cpio -ocv > /xxx/yyy/myfile.cpio
If you want to send it to tape:
find . -print | cpio -ocBv > /dev/rmt/0m
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-22-2005 09:34 AM
02-22-2005 09:34 AM
Re: cpio
find . -depth -xdev -print | cpio -dump /newmountpoint
Hope this helps
B
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-22-2005 09:37 AM
02-22-2005 09:37 AM
Re: cpio
cd /source_dir
find . -xdev -depth | cpio -oBdvmxc > /dev/rmt/0m
This would take all the files in /source_dir and all of the files in all of the subdirectories of /source_dir and put them on the tape drive.
find options...
"xdev" -makes sure it doesn't cross mount points.
"depth" uses a depth first search instead of a breadth first search - recommended.
cpio options
"o" - output
"B" - large blocks
"d" - create directories as needed - probably don't need when making a tape - but I like using it both in and out - so my command looks almost the same on extract... bad excuse I know...
"v" verbose
"m" preserve modification times
"x" preserves special files (think /dev)
"c" ascii format - b/c I like it better.
Now, to extract from the tape...
cpio -iBdvmuxc < /dev/rmt/0m ...
(keep in mind that the "u" is an option for overwriting a newer file with an older one).
HTH
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-22-2005 09:38 AM
02-22-2005 09:38 AM
Re: cpio
find . -depth | cpio -pdlmuva /destination_dir
-USA..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-23-2005 10:03 AM
02-23-2005 10:03 AM
Re: cpio
find . -print | cpio -ocv > myfile.cpio
But I cannot recover it. I have tried with:
cpio -idcmv > myfile.cpio
cpio -idmv > myfile.cpio
Any idea?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-23-2005 06:27 PM
02-23-2005 06:27 PM
Re: cpio
Check the redirection symbol
Is it not "<" instead of ">"
Rgds
Suraj