From: Bill Thompson (bill.thompson@GOODYEAR.COM)
Date: Mon Jul 21 2003 - 15:00:32 EDT
I know, you've already seen a number of ways to do this, but here's one
more:
cd from_directory
find . -xdev -print | backup -iqf - | (cd new_directory; restore -xf -)
Why use this method rather than tar or cpio? Well, backup/restore are AIX
specific commands. If any of the files you are copying are sparse files,
tar or cpio will expand them, backup/restore will not. Your copied files
can take more space using tar or cpio. The can actually take *LESS* space
using backup/restore. Also, if you are using ACL's (access control), you
will lose them with tar or cpio but you will not with backup/restore.
If I'm doing the copy on an AIX system, I always use backup/restore.
Bill Thompson
Sr UNIX Systems Administrator
The Goodyear Tire & Rubber Co.
Contains Confidential and/or Proprietary Information
May Not Be Copied or Disseminated Without Express Consent of The Goodyear
Tire & Rubber Company.
AIX-L Archives: http://marc.theaimsgroup.com/?l=aix-l&r=1&w=2
----- Original Message -----
From: Ranbir Singh
Newsgroups: bit.listserv.aix-l
To: aix-l@Princeton.EDU
Sent: Monday, July 21, 2003 12:37 PM
Subject: How to Copy Directory Structure w/o Copying Files
I am trying to copy the entire substructure of a directory to another
directory. How can I do this without copying the actual files in those
subdirectories as well?
Thanks for your help,
RS
--------------------------------
"Colorless green ideas sleep furiously."
--------------------------------
Ranbir Singh
Information Systems and Services
O: 513.745.3889
E: singh@xavier.edu
Xavier University
3800 Victory Parkway
Cincinnati, Ohio 45207-7411
This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 22:17:03 EDT