Path: utzoo!yunexus!geac!syntron!jtsv16!uunet!ncrlnk!ncrcae!ece-csc!ncsuvx!gatech!bloom-beacon!apple!bionet!agate!ucbvax!unisoft!paul From: paul@unisoft.UUCP (n) Newsgroups: comp.unix.aux Subject: Re: copying A/UX Message-ID: <1323@unisoft.UUCP> Date: 11 Oct 88 17:01:11 GMT Article-I.D.: unisoft.1323 References: <13935@mimsy.UUCP> <4392@polya.Stanford.EDU> Reply-To: paul@unisoft.UUCP (Paul Campbell) Lines: 68 In article <4392@polya.Stanford.EDU> kaufman@polya.Stanford.EDU (Marc T. Kaufman) writes: > >Assuming that the file system on the larger drive is mounted on /mnt : > > find /dev -depth -print | cpio -pdm /mnt > >works properly (when invoked from /). > >Marc Kaufman (kaufman@polya.stanford.edu) find /dev -depth -print | cpio -puldm /mnt If you want to keep user ids and links (there are links in /dev and owners are important for security) correct. Actually I copy volumes to LARGER volumes by: 1) sync 2) dd if= of= bs=500k 3) adb -w 4) 202?W 5) ^D 6) fsck -y You can get away with this when copying to a smaller volume IF YOU KNOW THAT THE LAST PART OF THE FREE LIST IS EMPTY. Obviously don't try this if you are unsure of what you are doing, the scope for disaster is LARGE. If you are copying one disk to another where neither one is root then cpio is the way to go, you can do everything in one fell swoop: To copy /fred to /mike cd fred;find . -print | cpio -puldm /mike One last rather unrelated tip: to keep a file system's free block list sorted (which encourages all the blocks on a file to live near each other) every so often unmount your file systems and fsck -S then remount them. For the root volume go to single user mode then run in on the block disk ie fsck -S /dev/dsk/c0d0s0 this will cause the system to reboot when it is done. Doing this is NOT required it just makes things run a little faster over the long run. It is an especially good idea to do BEFORE you add a large number of related files (or a small number of large files) that will stay on your disk for a long period of time. Paul -- Paul Campbell, UniSoft Corp. 6121 Hollis, Emeryville, Ca E-mail: ..!{ucbvax,hoptoad}!unisoft!paul Nothing here represents the opinions of UniSoft or its employees (except me) "Nuclear war doesn't prove who's Right, just who's Left" (ABC news 10/13/87)