Linux_FoundationLinux_Foundation
LFCS · Question #694
LFCS Question #694: Real Exam Question with Answer & Explanation
The correct answer is D: 0027. To ensure new files have default permissions of -rw- r----- (octal 640), the umask value should be set to 0027.
Submitted by ngozi_ng· Apr 18, 2026User and Group Management
Question
Which of the following settings for umask ensures that new files have the default permissions -rw- r----- ?
Options
- A0017
- B0640
- C0038
- D0027
Explanation
To ensure new files have default permissions of -rw- r----- (octal 640), the umask value should be set to 0027.
Common mistakes.
- A. A umask of 0017 would result in default file permissions of 666 - 017 = 650 (-rw-r-x---), which includes execute permission for the group.
- B. 0640 represents a permission mode itself, not a umask value; if used as a umask, it would drastically alter permissions in an unintended way.
- C. A umask of 0038 is not a valid octal representation for permissions because '8' is not a valid digit in octal numbering.
Concept tested. umask and file permission calculation
Reference. https://man7.org/linux/man-pages/man2/umask.2.html
Topics
#umask#file permissions#octal permissions#default permissions
Community Discussion
No community discussion yet for this question.