rsync groups in modules
dwd at bell-labs.com
Fri Sep 7 03:37:57 EST 2001
On Thu, Sep 06, 2001 at 06:03:32AM -0500, Holstein, Brian wrote:
> When rsync'ing to a module with rsync -a I have a file appear with the proper
> owner, but not the proper group set. Below is the module, is it functionally possible
> to hard set the group like the user while still using the -a flag with rsync.
> max connections = 25
> timeout = 600
> secrets file = /etc/rsyncd.secrets
> lock file = /var/tmp/rsyncd.lock
> list = yes
> comment = Release node for prod
> path = /unique/apps/par
> read only = no
> hosts allow = qa1 qa2
> auth users = bholstei
> uid = feprod
> gid = pardev
> I'm trying
> rsync --rsync-path=/usr/local/bin/rsync -a /tmp/foo prod1::release/foo2
> I'm transferring the file as uid=bholstei gid=op_sysad and
> what I get is a file that looks like
> -rw-r--r-- 1 feprod op_sysad 15 Sep 4 16:20 foo2
I'm guessing that you're running that daemon as root, correct? I guess
that because you don't have "use chroot = no".
I think the answer to your question is probabably "no" as long as you're
using -a. What "uid" and "gid" say when running as root is to do a setuid
to that user and group id, but with -og (which -a implies) it still tries to
preserve the user and group if it can.
Rsync enforces BSD-style rules for uids and gids. That is, users can't do
a chown to another user, and they can only do a chgrp to groups they're
in. So, I'm assuming that the "feprod" login is in the "op_sysad" group.
You could say "refuse options = group", but that causes it to refuse the
entire session and not just ignore the option.
- Dave Dykstra
More information about the rsync