[clug-talk] Umask Question
Jon
me at jonwatson.ca
Fri Oct 27 17:30:09 PDT 2006
Not to disrupt the radio thread, but I have a Umask question...
I have been operating under the understanding that the umask value is
basically subtracted from the default file permissions for newly created
files and directories on a system. On my system, for example, the
default permissions for files are 0666 and the umask is 0022.
I have verified that newly created files on my system have -rw-r--r--
permissions which is consistent with a 0666 default permission and a
umask of 0022.
However, when I change the umask to 0731, my newly created files have
----r--rw- as their permissions. It seems to me that they should have
-----wxr-x.
What's even weirder, if I 'subtract' 0731 from 0777, then I end up with
the ----r--rw-, but 0777 isn't the default file permissions on my
system. I have set the umask to 0 and created a new file in order to
verify the default file permissions are working and they do as newly
created files with a umask of 0 are created with 0666 perms.
Am I missing something supremely obvious here? I'm quite confused....
J
More information about the clug-talk
mailing list