This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: rsync problems from Vista installed cygwin, ok on XP


On Mon, 20 Aug 2007, DaveB wrote:

> Corinna Vinschen-2 wrote:
> >
> > On Aug 18 21:06, DaveB wrote:
> >> So... two interesting followon points...
> >>
> >> 1. Why didn't the ACLs get set to something reasonable as opposed to
> >> 000 in the first place when I created this little test area in Vista?
> >> After all, I
> >
> > The directory has been created using native Windows tools.  The
> > permissions given using native Windows tools *are* strange and don't
> > follow POSIX rules. It's perfectly valid that you can access a
> > directory under Windows but get 000 POSIX permissions.  You did see
> > the '+' at the end of the permission in ls -l?
>
> OK, I now see this + and had no idea what it meant... but have now found
> the doc in cygwin by typing "info ls", where it says...
>
>      Following the file mode bits is a single character that specifies
>      whether an alternate access method such as an access control list
>      applies to the file.  When the character following the file mode
>      bits is a space, there is no alternate access method.  When it is
>      a printing character, then there is such a method.
>
>      For a file with an extended access control list, a `+' character is
>      listed.  Basic access control lists are equivalent to the
>      permissions listed, and are not considered an alternate access
>      method.
>
> Interesting.  So if it knows there is an ACL which overrides the ------
> permissions that were inherited from C:\ then why can't the cygwin port
> of rsync allow a Windows-friendly option for rsync'ing these files...
> even if it cannot directly read the ACL maybe it could allow you to
> invoke some special rsync permissions sync'ing flag?
>
> I looked in the man rsync doc, and found some flags that might be
> helpful ... namely -p -E and --chmod.  But even chmod=XXX doesn't quite
> let you do automatically what would make sense, which is to create
> rsync'd files with rwx for the exe's and rw for the others.
>
> Not sure what the best way out of here is...??? I'm beginning to
> understand this a bit better, but it sure is a minefield... will
> generate ongoing problems for innocent future users.

You misunderstand your problem.  The problem is not that rsync on the
source side cannot read the files (it can, since the ACLs allow it to).
The problem is that the rsync on the destination side copies only the Unix
permission bits from the source side (which are 000), and then it is
unable to write to that directory (because the permissions are 000).

What you want is some way of getting rsync to not copy permissions, or
making rsync ACL-aware.  I don't know of any way to do either, but then, I
haven't used rsync extensively.  Perhaps the documentation holds the
answer.

> PS Can anyone point to a good article on ACL that explains the
> relationship to these ls -l permissions also?

I'm sure MSDN has a lot of info on ACLs in general and on their use in
Windows.  If you want to know specifically how Cygwin maps ACLs to Unix
permission bits, see <http://cygwin.com/cygwin-ug-net/ntsec.html>.
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_	    pechtcha@cs.nyu.edu | igor@watson.ibm.com
ZZZzz /,`.-'`'    -.  ;-;;,_		Igor Peshansky, Ph.D. (name changed!)
     |,4-  ) )-,_. ,\ (  `'-'		old name: Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

Belief can be manipulated.  Only knowledge is dangerous.  -- Frank Herbert

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]