How to set different permissions on target

Kevin Korb kmk at
Sat Dec 21 12:18:07 MST 2013

Hash: SHA1

The current version of rsync does have a --chown option.  If you don't
have the current version then the solution is simply to run rsync as
that user and it will have no choice but to use that ownership.

On 12/21/2013 01:42 PM, Charles Marcus wrote:
> Hi all,
> Ok, I'm attempting to rsync a large datastore (email), and want to 
> change the ownership of the target directories and files.
> I saw the --chmod option in man rsync, but didn't see a --chown
> option...
> What I'd like to do is something like:
> rsync -avHP --chown vmail:vmail /mnt/old-mail/ /var/vmail/mail/
> So the ownership of all dirs and file on the target are
> vmail:vmail after the rsync is done (on the source they are
> postfix:postfix).
> Can this be done? This is about 350GB of stuff, so I'd rather not
> have to do a separate chown after the rsyn each time (I'll be doing
> this multiple times).
> Thanks,
> Charles

- -- 
	Kevin Korb			Phone:    (407) 252-6853
	Systems Administrator		Internet:
	FutureQuest, Inc.		Kevin at  (work)
	Orlando, Florida		kmk at (personal)
	Web page:
	PGP public key available on web site.
Version: GnuPG v2.0.22 (GNU/Linux)
Comment: Using GnuPG with Thunderbird -


More information about the rsync mailing list