On Sunday, December 22, 2002 11:59 AM, Steve Fosdick wrote:
I can't say for sure if this the best way, but what I have always done for a situation like this is to use filename patterns to match the things I want to copy and exclude the one I don't.
As an example, my root directory looks like this:
bin dev home lost+found proc tmp vmlinuz boot etc initrd mnt root usr vmlinuz.old cdrom floppy lib opt sbin var
so assuming the new partition is mounted on /mnt/root I would say:
cp -a [b-l]* [o-t]* v* /mnt/root
I am specifying those directories I want to copy by range, based on the first letter...
Thanks for the suggestion Steve. I must admit I did actually use the cp command to copy /home to the new partition without problems but have a nagging worry in the back of my head that someone on the list had loads of hassle trying to copy system directories earlier in the year. I seem to remember it was symbolic links and special system files which didn't copy correctly and caused the problems. Unfortunately, although I found the message thread interesting I forgot to write down the eventual solution but I *think* in the end they used a short shell script which used ls to read in the directory names, the resulting list being tweaked somehow within the script before being passed to tar (or may have been cpio???) to do the actual copying. Unfortunately I forgot to write the script down. I guess though you are correct and the simplest thing would be for me to try the cp command string you suggested first and see what happens on the subsequent bootup (after editing fstab and rerunning lilo).
Thanks for your help,
Ian.