on Sun, Dec 22, 2002 at 01:54:31PM +0000, Richard Kettlewell wrote:
"cp -a" should work fine. Other possible invocations of cp might well cause problems, and AFAIK all the non-GNU versions of cp don't have the feature at all...
they do. SuSv3 has it -- just not as -a, which is a gnu extension. cp -RPp is the SuSv3 and POSIX way.
another way of doing it in a POSIX/SuSv3 environment is using pax. e.g. pax -rw -pe foo* bar* /mnt/root
or if you lack pax, tar -cf - foo | (cd /mnt/root; tar -xf -)