Unsolicited change of group

BlakJak blakjak at blakjak.sytes.net
Wed Oct 8 19:57:07 EST 2003


Using rsync to copy files on the localhost, the group is being preserved 
even though I have not used the -g or -a options.

My source files:
$ ls -l ~/working/source/path
-rwxr-xr-x    1 blakjak  blakjak       115 Oct  8 01:37 foo.php
-rwxr-xr-x    1 blakjak  blakjak      6285 Oct  8 01:37 bar.php

My destination:
$ ls -l /active/path
-rwxr-x---    1 blakjak  wwwadmin      115 Oct  8 02:06 foo.php
-rwxr-x---    1 blakjak  wwwadmin     6285 Oct  8 02:06 bar.php

$ touch foo.php
$ rsync -Curv --exclude='.*' --exclude='*~' ~/working/source/path/ 
/active/path
$ ls -l /active/path
-rwxr-x---    1 blakjak  blakjak       115 Oct  8 20:05 foo.php
-rwxr-x---    1 blakjak  wwwadmin     6285 Oct  8 02:06 bar.php

----

Note that the permissions on the destination files have been left alone, 
but the group has been changed.

The man page indicates that group will only be preserved if you use the 
-g option (or by extension, the -a option), which I have not.  There is 
no option to disable the preservation of group.  Therefore the default 
behaviour in all cases should be to _not_ preserve group unless the user 
specifies otherwise.  I can't understand why rsync is altering the 
destination files in this way.

If you can shed any light on this, I'd love to hear from you.

BJ






More information about the rsync mailing list