* Copying file systems.
@ 1996-06-24 23:25 mortimer
0 siblings, 0 replies; only message in thread
From: mortimer @ 1996-06-24 23:25 UTC (permalink / raw)
To: tru64-unix-managers
Hi
I recently had to copy a complete file system from one disk
to another. Naively I first tried `cp -pR`. As you probably
realize this didn't work. Specifically, in order of increasing
seriousness:
o Directories had their modification times set to the
time of copying rather than the same time as the source.
o Files with the sticky bit set on the source did not have
the sticky bit set on the destination.
o Symbolic links were recreated as promised by the -R option
but they had the wrong owner:group set. All recreated
symbolic links had root:system as owner:group.
With the help of the archives for this mailing list I discovered
that the correct way to copy a complete file system was with dump
and restore. Specifically
dump -0f - file_system | (cd /mnt; restore -vrf -)
does what I wanted.
My problem is that I sometimes need to move a user's area from
one disk to another. Since this is only part of a file system
I can't use dump and restore although I suppose I could use tar
in a similar way.
Why doesn't `cp -pR` work the way I expected. Is this a bug with
cp (we are running OSF1 v3.2 214) or is it supposed to work this way.
Ian Mortimer
Department of Physics Tel : +61 7 3365 3416
University of Queensland Email: mortimer@physics.uq.edu.au
St. Lucia, Brisbane Fax : +61 7 3365 1242
Queensland, Australia. 4072.
Disclaimer: Any opinions expressed are my own and do not represent those
of the University of Queensland or the Department of Physics.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1996-06-24 23:25 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1996-06-24 23:25 Copying file systems mortimer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox