XK0-005 · Question #767
XK0-005 Question #767: Real Exam Question with Answer & Explanation
The correct answer is D: umask 0077. Setting the umask to 0077 causes new directories to be created with 0777–0077 = 0700 (rw‑x only for the owner) and new files with 0666–0077 = 0600 (rw only for the owner), which matches the requirement of read/write on files and read/write/execute on the directory.
Question
A Linux administrator needs to set the permissions on a server. The administrator wants to have the files within the directory set to read-write permissions and the directory set to read-write- execute permissions. Which of the following commands should the administrator use?
Options
- Achmod 0022
- Bchown 0027
- Csetfacl 0007
- Dumask 0077
Explanation
Setting the umask to 0077 causes new directories to be created with 0777–0077 = 0700 (rw‑x only for the owner) and new files with 0666–0077 = 0600 (rw only for the owner), which matches the requirement of read/write on files and read/write/execute on the directory.
Topics
Community Discussion
No community discussion yet for this question.