On Fri, Dec 12, 2003 at 02:31:40PM +1100, John Clarke wrote:
> On Fri, Dec 12, 2003 at 03:25:49PM +1100, Peter Vogel wrote:
> 
> > I used scp -pr but all the files end up being owned by "root".
> > 
> > I thought -p will preserve everything.  But the man page on my RH8
> > installation does not say it does.  Is this a version problem?
> 
>      -p      Preserves modification times, access times, and modes from
>              the original file.
> 
> There's nothing there about preserving user and group.  If you want to
> do that, try rsync (use -a).  Even then, that only root (on the
> destination host) can fully preserve user and group information because
> ordinary users don't have privilege to set user to anyone else or group
> to any group of which they're not a member.

I agree about trying rsync.  It's the best in many ways.
You can also use tar.  AFAIK you can choose (in tar at least)
to preserve names instead of uids/gids, which might work better if the 
uids/gids aren't synchronised between the machines.

Patrick
-- 
SLUG - Sydney Linux User's Group - http://slug.org.au/
More Info: http://lists.slug.org.au/listinfo/slug

Reply via email to