chmod does not work as expected

Chris Faylor cgf@cygnus.com
Sat Sep 2 19:28:00 GMT 2000


On Sat, Sep 02, 2000 at 04:01:56PM -0700, Winbox X wrote:
>I wonder if someone noticed this. After I chmod of a file
>a 'ls -l' tell me nothing is changed for the mod of the Group and Others.

Windows NT and 95, by default, have very different permission layouts
from UNIX.  SO, only the 'r' option of chmod (chmod +r foo) really has
any meaning.

On Windows NT, however, if the CYGWIN environment variable contains
'ntsec' then you can get UNIX-like permissions on NTFS drives.  Using
the somewhat deprecated 'ntea' allows you to get UNIX-like permissions
on NTFS and FAT drives but a huge (very hard to delete) file is created
on FAT drives when you do this.

On Windows 95, there are no alternatives.  You have to be content with
twiddling 'chmod -r'.

So, if you can use CYGWIN=ntsec then that's the best solution.  It turns
on all sorts of UNIX-like security in Cygwin.

Otherwise, you're right, 'chmod' doesn't do much.

Christopher Faylor
Cygwin Engineering Manager
Red Hat, Inc.

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com



More information about the Cygwin mailing list