A
A
Alexander Karpov2017-08-09 07:19:47
linux
Alexander Karpov, 2017-08-09 07:19:47

Why after "umask u=rwx,g=rwx,o=" the generated files don't have permission to run?

Actually a subject.
umask u=rwx,g=rwx,o=
touch testfile
ls -l
output:
-rw-rw---- 1 karpovam clouds 0 Aug 9 11:15 testfile
and where is the cherished and expected -rwx-rwx--- ?? ? If anyone knows, please tell me.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
J
jcmvbkbc, 2017-08-09
@Inkognitoss

touch test file

Using strace, you can see that touch opens the file with mode = 0666, so there is no x to come from:
$ strace -v -e open touch test
open("test", O_WRONLY|O_CREAT|O_NOCTTY|O_NONBLOCK, 0666) = 3

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question