Without spending some time going through your assorted Windows file permissions, it's hard to say exactly what's going wrong.
Thankfully, I don't need to know that. The simple fix to resolve all your file permission woes is to use the
noacl option for all the Cygwin mounts.
/etc/fstab in your favourite Cygwin text editor (or, normally,
C:\cygwin\etc\fstab in your favourite Windows one, provided it supports Unix line-endings [so not Notepad]). Mine previously looked like this:
# For a description of the file format, see the Users Guide
# This is default anyway:
# none /cygdrive cygdrive binary,posix=0,user 0 0
If that last line is still commented out, delete the leading
# so the system will pay attention to it. It may not be commented out, in which case there'll be no
# to delete.
Then, to the list of options (that's the
binary,posix=0,user bit), add
,noacl to the end. The relevant line in my
/etc/fstab then looked like the below:
none /cygdrive cygdrive binary,posix=0,user,noacl 0 0
Then close and reopen all your Cygwin applications (you may need to reboot), and you should stop seeing any permissions issues.
Note that if you've been doing complicated things with your mount points, you may need to edit multiple lines in
/etc/fstab, as well as any files that have accumulated in
/etc/fstab.d. The changes you'll need to make will be the same for all of these.
noacl option will result in Cygwin completely ignoring all NTFS access control lists. It'll still look at the DOS read-only attribute, but that's not tied to any user. This means it won't be able to tell if a file is executable based off permissions, either; instead, it assumes any file ending
.exe is executable, as well as any file starting with
Further reading, if you're interested, from the Cygwin User's Guide: